diff options
author | Edward O'Callaghan <eocallaghan@alterapraxis.com> | 2014-07-07 19:58:53 +1000 |
---|---|---|
committer | Patrick Georgi <patrick@georgi-clan.de> | 2014-07-18 07:41:52 +0200 |
commit | d5339ae0b73b46f65c1d88fd4066a0e98f09b6b3 (patch) | |
tree | 47580da970ec698f583685f02ef363da06336af4 /src/mainboard/gizmosphere/gizmo | |
parent | cd47560f2ae0758012001d6d954653b4526811ad (diff) | |
download | coreboot-d5339ae0b73b46f65c1d88fd4066a0e98f09b6b3.tar.xz |
mainboard: Make use of ARRAY_SIZE in buildOpts.c on AGESA platforms
Found using coccinelle.
Change-Id: I406de6cfe25d3b471dbb6f98d9c62addae008de3
Signed-off-by: Edward O'Callaghan <eocallaghan@alterapraxis.com>
Reviewed-on: http://review.coreboot.org/6195
Tested-by: build bot (Jenkins)
Reviewed-by: Patrick Georgi <patrick@georgi-clan.de>
Diffstat (limited to 'src/mainboard/gizmosphere/gizmo')
-rwxr-xr-x | src/mainboard/gizmosphere/gizmo/buildOpts.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/mainboard/gizmosphere/gizmo/buildOpts.c b/src/mainboard/gizmosphere/gizmo/buildOpts.c index 5e496e11ec..613b3bc90e 100755 --- a/src/mainboard/gizmosphere/gizmo/buildOpts.c +++ b/src/mainboard/gizmosphere/gizmo/buildOpts.c @@ -34,6 +34,8 @@ * @e \$Revision: 23714 $ @e \$Date: 2009-12-09 17:28:37 -0600 (Wed, 09 Dec 2009) $ */ +#include <stdlib.h> + #include "Filecode.h" #define FILECODE PLATFORM_SPECIFIC_OPTIONS_FILECODE @@ -451,7 +453,7 @@ CONST UINT8 AGESA_MEM_TABLE_ON[][sizeof (MEM_TABLE_ALIAS)] = // TABLE END NBACCESS (MTEnd, 0, 0, 0, 0, 0), // End of Table }; -CONST UINT8 SizeOfTableON = sizeof (AGESA_MEM_TABLE_ON) / sizeof (AGESA_MEM_TABLE_ON[0]); +CONST UINT8 SizeOfTableON = ARRAY_SIZE(AGESA_MEM_TABLE_ON); /* *************************************************************************** * Optional User code to be included into the AGESA build |