From 10d0a81ec1c6ccedac291824eed8980d011b0ab9 Mon Sep 17 00:00:00 2001 From: Stefan Reinauer Date: Fri, 5 Sep 2008 15:18:15 +0000 Subject: define array size in a single place (trivial) Signed-off-by: Stefan Reinauer Acked-by: Stefan Reinauer git-svn-id: svn://svn.coreboot.org/coreboot/trunk@3566 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1 --- payloads/coreinfo/pci_module.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/payloads/coreinfo/pci_module.c b/payloads/coreinfo/pci_module.c index 3407cbe86d..5b1a9d8785 100644 --- a/payloads/coreinfo/pci_module.c +++ b/payloads/coreinfo/pci_module.c @@ -29,7 +29,8 @@ struct pci_devices { unsigned int id; }; -static struct pci_devices devices[64]; +#define MAX_PCI_DEVICES 64 +static struct pci_devices devices[MAX_PCI_DEVICES]; static int devices_index; /* Number of entries to show in the list */ @@ -190,7 +191,7 @@ static void pci_scan_bus(int bus) continue; /* FIXME: Remove this arbitrary limitation. */ - if (devices_index >= 64) + if (devices_index >= MAX_PCI_DEVICES) return; devices[devices_index].device = -- cgit v1.2.3