]> git.ipfire.org Git - thirdparty/u-boot.git/commitdiff
smbios: Fix wrong sysinfo ID for Type 3 enclosure asset tag
authorFrank Böwingloh <f.boewingloh@beckhoff.com>
Fri, 5 Jun 2026 07:33:31 +0000 (09:33 +0200)
committerTom Rini <trini@konsulko.com>
Mon, 8 Jun 2026 19:29:03 +0000 (13:29 -0600)
smbios_write_type3() uses SYSID_SM_BASEBOARD_ASSET_TAG (Type 2) instead
of SYSID_SM_ENCLOSURE_ASSET_TAG (Type 3) for the enclosure asset tag.
This causes the enclosure's asset tag to be read from the baseboard
sysinfo field rather than the enclosure-specific one.

Fixes: bcf456dd ("smbios: add detailed smbios information")
Signed-off-by: Frank Böwingloh <f.boewingloh@beckhoff.com>
Cc: Raymond Mao <raymondmaoca@gmail.com>
Cc: Tom Rini <trini@konsulko.com>
Cc: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Reviewed-by: Raymond Mao <raymondmaoca@gmail.com>
lib/smbios.c

index 906d275351773b301f9d8217a6a90729de4e3c8c..afde6401ae5a1f869c8ef7b40afea69b9c4542a4 100644 (file)
@@ -679,7 +679,7 @@ static int smbios_write_type3(ulong *current, int *handle,
        t->serial_number = smbios_add_prop_si(ctx, "serial",
                                              SYSID_SM_ENCLOSURE_SERIAL, NULL);
        t->asset_tag_number = smbios_add_prop_si(ctx, "asset-tag",
-                                                SYSID_SM_BASEBOARD_ASSET_TAG,
+                                                SYSID_SM_ENCLOSURE_ASSET_TAG,
                                                 NULL);
        t->oem_defined = smbios_get_val_si(ctx, "oem-defined",
                                           SYSID_SM_ENCLOSURE_OEM, 0);