summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSven Schnelle <svens@stackframe.org>2012-06-20 10:23:31 +0200
committerSven Schnelle <svens@stackframe.org>2012-06-20 12:46:39 +0200
commit2f8c4f829e7eab2563dfb9d17d8c93d9070f7c45 (patch)
tree0af93e9d635e272b2eb2616f9e354cb830d29323
parent2fcc166fb89f85fc91bf5270a0d0973feb077cab (diff)
downloadcoreboot-2f8c4f829e7eab2563dfb9d17d8c93d9070f7c45.tar.xz
mptable: initialize apic/bus arrays with ARRAY_SIZE
and increase the busses size to 32, as 16 isn't enough one some systems (i5000 for example) Change-Id: Ie09f451dd82ac25b0de85fd47807136e01da737b Signed-off-by: Sven Schnelle <svens@stackframe.org> Reviewed-on: http://review.coreboot.org/1114 Tested-by: build bot (Jenkins)
-rw-r--r--util/mptable/mptable.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/util/mptable/mptable.c b/util/mptable/mptable.c
index e2818610b6..e2845765e6 100644
--- a/util/mptable/mptable.c
+++ b/util/mptable/mptable.c
@@ -276,7 +276,7 @@ static void pnstr(uint8_t * s, int c);
/* global data */
int pfd; /* physical /dev/mem fd */
-int busses[16];
+int busses[32];
int apics[16];
int ncpu;
@@ -787,9 +787,10 @@ static void MPConfigTableHeader(uint32_t pap)
}
/* initialze tables */
- for (x = 0; x < 16; ++x) {
- busses[x] = apics[x] = 0xff;
- }
+ for(x = 0; x < ARRAY_SIZE(busses); x++)
+ busses[x] = UNKNOWN_BUSTYPE;
+ for(x = 0; x < ARRAY_SIZE(apics); x++)
+ apics[x] = 0xff;
ncpu = 0;
nbus = 0;