CHROMIUM: EFI: Don't export invalid SMBIOS base
With a non-EFI system there will not be a valid SMBIOS base exported
in an EFI table. On these systems the exported value in
/sys/kernel/debug/efi_smbios_base is ~0UL which means dmidecode
may attempt to access memory there and trigger a kernel panic.
This change checks the base against the initialized value of
EFI_INVALID_TABLE_ADDR and does not create the sysfs node in
that case.
BUG=chromium-os:31577
TEST=successfully run dmidecode on coreboot based platform
Change-Id: I16dcaa80bc7a41fbab81ff3c482460a0f86ac0ac
Signed-off-by: Duncan Laurie <dlaurie@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/24616
Reviewed-by: Olof Johansson <olofj@chromium.org>