]> git.dujemihanovic.xyz Git - u-boot.git/commit
smbios: use struct_table_length to get SMBIOS 2.1 total table length
authorMasahisa Kojima <masahisa.kojima@linaro.org>
Thu, 25 Jan 2024 01:11:28 +0000 (10:11 +0900)
committerHeinrich Schuchardt <heinrich.schuchardt@canonical.com>
Fri, 26 Jan 2024 13:16:46 +0000 (14:16 +0100)
commitb92d0f78dc04f6f7dd8b67cb9ea1bc1dc3b51aa6
treef88abf42bf0eca52a8715f87777e161ee829435e
parent2497f6a84c0b906551d08054a631b86942cb4fa9
smbios: use struct_table_length to get SMBIOS 2.1 total table length

The current code convert the SMBIOS 2.1 entry point structure to
SMBIOS 3.0 entry point structure. The max_struct_size member in
SMBIOS 2.1 entry point structure indicates
"Size of the largest SMBIOS structure, in bytes".
We need to use struct_table_length instead.

Fixes: 1c5aab803c0b ("smbios: copy QEMU tables")
Signed-off-by: Masahisa Kojima <masahisa.kojima@linaro.org>
Reviewed-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
drivers/misc/qfw_smbios.c