summaryrefslogtreecommitdiff
path: root/src/arch
diff options
context:
space:
mode:
Diffstat (limited to 'src/arch')
-rw-r--r--src/arch/x86/smbios.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/arch/x86/smbios.c b/src/arch/x86/smbios.c
index 7b6dda18fa..5784beb088 100644
--- a/src/arch/x86/smbios.c
+++ b/src/arch/x86/smbios.c
@@ -292,7 +292,13 @@ static int smbios_write_type0(unsigned long *current, int handle)
#endif
#endif /* CONFIG_CHROMEOS */
- t->bios_rom_size = (CONFIG_ROM_SIZE / 65535) - 1;
+ /* As a work around to prevent a compiler error, temporarily specify
+ * 16 MiB flash sizes when ROM size >= 16 MiB. An update is necessary
+ * once the SMBIOS specification addresses ROM sizes > 16 MiB.
+ */
+ uint32_t rom_size = CONFIG_ROM_SIZE;
+ rom_size = MIN(CONFIG_ROM_SIZE, 16 * MiB);
+ t->bios_rom_size = (rom_size / 65535) - 1;
t->system_bios_major_release = 4;
t->bios_characteristics =