diff options
Diffstat (limited to 'src/southbridge/nvidia/ck804/ck804_lpc.c')
-rw-r--r-- | src/southbridge/nvidia/ck804/ck804_lpc.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/southbridge/nvidia/ck804/ck804_lpc.c b/src/southbridge/nvidia/ck804/ck804_lpc.c index 69afb182ae..b06de3e558 100644 --- a/src/southbridge/nvidia/ck804/ck804_lpc.c +++ b/src/southbridge/nvidia/ck804/ck804_lpc.c @@ -15,6 +15,7 @@ #include <bitops.h> #include <arch/io.h> #include <cpu/x86/lapic.h> +#include <stdlib.h> #include "ck804.h" #define CK804_CHIP_REV 2 @@ -82,7 +83,7 @@ static void setup_ioapic(unsigned long ioapic_base) l = (unsigned long *) ioapic_base; - for (i = 0; i < sizeof(ioapicregvalues) / sizeof(ioapicregvalues[0]); + for (i = 0; i < ARRAY_SIZE(ioapicregvalues); i++, a++) { l[0] = (a->reg * 2) + 0x10; l[4] = a->value_low; |