[PATCH 1/2 v2] smbios: Simplify reporting of unknown values

Tom Rini trini at konsulko.com
Mon Nov 27 19:13:55 CET 2023


On Mon, Nov 27, 2023 at 07:10:57PM +0200, Ilias Apalodimas wrote:

> If a value is not valid during the DT or SYSINFO parsing,  we explicitly
> set that to "Unknown Product" and "Unknown" for the product and
> manufacturer respectively.  It's cleaner if we move the checks insisde
> smbios_add_string() and always report "Unknown" regardless of the missing
> field.
> 
> pre-patch dmidecode
> <snip>
> Handle 0x0001, DMI type 1, 27 bytes
> System Information
>         Manufacturer: Unknown
>         Product Name: Unknown Product
>         Version: Not Specified
>         Serial Number: Not Specified
>         UUID: Not Settable
>         Wake-up Type: Reserved
>         SKU Number: Not Specified
>         Family: Not Specified
> 
> [...]
> 
> post-patch dmidecode:
> 
> Handle 0x0001, DMI type 1, 27 bytes
> System Information
>         Manufacturer: Unknown
>         Product Name: Unknown
>         Version: Unknown
>         Serial Number: Unknown
>         UUID: Not Settable
>         Wake-up Type: Reserved
>         SKU Number: Unknown
>         Family: Unknown
> [...]
> 
> Signed-off-by: Ilias Apalodimas <ilias.apalodimas at linaro.org>
> Reviewed-by: Peter Robinson <pbrobinson at gmail.com>
> Tested-by: Peter Robinson <pbrobinson at gmail.com>

Reviewed-by: Tom Rini <trini at konsulko.com>

-- 
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 659 bytes
Desc: not available
URL: <https://lists.denx.de/pipermail/u-boot/attachments/20231127/785d5e5c/attachment.sig>


More information about the U-Boot mailing list