mirror of
https://github.com/fail0verflow/switch-coreboot.git
synced 2025-05-04 01:39:18 -04:00
define array size in a single place (trivial)
Signed-off-by: Stefan Reinauer <stepan@coresystems.de> Acked-by: Stefan Reinauer <stepan@coresystems.de> git-svn-id: svn://svn.coreboot.org/coreboot/trunk@3566 2b7e53f0-3cfb-0310-b3e9-8179ed1497e1
This commit is contained in:
parent
0e0ecf27bb
commit
10d0a81ec1
1 changed files with 3 additions and 2 deletions
|
@ -29,7 +29,8 @@ struct pci_devices {
|
||||||
unsigned int id;
|
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;
|
static int devices_index;
|
||||||
|
|
||||||
/* Number of entries to show in the list */
|
/* Number of entries to show in the list */
|
||||||
|
@ -190,7 +191,7 @@ static void pci_scan_bus(int bus)
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
/* FIXME: Remove this arbitrary limitation. */
|
/* FIXME: Remove this arbitrary limitation. */
|
||||||
if (devices_index >= 64)
|
if (devices_index >= MAX_PCI_DEVICES)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
devices[devices_index].device =
|
devices[devices_index].device =
|
||||||
|
|
Loading…
Add table
Reference in a new issue