[PATCH 00/10] SMBIOS improvements

Simon Glass sjg at chromium.org
Mon Aug 26 19:58:54 CEST 2024


Hi Caleb,

On Mon, 19 Aug 2024 at 17:03, Caleb Connolly <caleb.connolly at linaro.org> wrote:
>
> Hi Simon,
>
> > As a general comment, this is adding a load of code which is used by a
> > lot of platforms. As more and more aarch64 platforms are created, this
> > data grows. Why not use the devicetree for this hardware information?
> > That is what it is for.
>
> This data does not belong in devicetree, the various system registers
> exist to describe this information... Putting it in DT would be
> duplicating it.

I am not wanting to duplicate info which can be read from system registers.

>
> Using DT for this would additionally require having bindings accepted
> upstream and for all SoCs to add them. To what end?

To get the correct information in there. How are boards supposed to
add SMBIOS info? Do we end up creating a whole infra in U-Boot just
for the driver to read it out? It just doesn't make any sense to me...

Let's put hardware info in the DT where it belongs.

>
> That being said, it would maybe be good to know what the size diff is
> with this series before getting into the weeds.
>
> >
> > Some of the information detected makes sense, such as cache setup, but
> > some of it seems like an approximation, or is missing, but suggests it
> > is authoritative.
>
> Could you give some examples?

Here is an excerpt from the patch, you can see various things which
are incorrect or too general.

      .sys.manufacturer = "arm",
+       .sys.prod_name = "arm",
+       .sys.version = "armv8",
+       .sys.sn = "Not Specified",
+       .sys.wakeup_type = SMBIOS_WAKEUP_TYPE_UNKNOWN,
+       .sys.sku_num = "Not Specified",
+       .sys.family = "arm",
+
+       /* Baseboard (or Module) Information */
+       .board.manufacturer = "arm",
+       .board.prod_name = "arm",
+       .board.version = "armv8",
+       .board.sn = "Not Specified",
+       .board.asset_tag = "Not Specified",
+       .board.feature.fields.hosting_board = 1, /* host board */
+       .board.chassis_locat = "Not Specified",
+       .board.type = SMBIOS_BOARD_MOTHERBOARD,
+
+       /* System Enclosure or Chassis Information */
+       .chassis.manufacturer = "arm",
+       .chassis.version = "armv8",
+       .chassis.sn = "Not Specified",
+       .chassis.asset_tag = "Not Specified",
+       .chassis.chassis_type = SMBIOS_ENCLOSURE_DESKTOP,
+       .chassis.bootup_state = SMBIOS_STATE_SAFE,
+       .chassis.power_supply_state = SMBIOS_STATE_SAFE,
+       .chassis.thermal_state = SMBIOS_STATE_SAFE,
+       .chassis.security_status = SMBIOS_SECURITY_NONE,
+       .chassis.oem_defined = SMBIOS_ENCLOSURE_OEM_UND,
+       .chassis.height = SMBIOS_ENCLOSURE_HEIGHT_UND,
+       .chassis.number_of_power_cords = SMBIOS_POWCORD_NUM_UND,
+       .chassis.element_count = ARRAY_SIZE(contained_elements),
+       .chassis.element_record_length = sizeof(contained_elements[0]),
+       .chassis.elements = &contained_elements[0],
+       .chassis.elements_size = sizeof(contained_elements),
+       .chassis.sku_num = "Not Specified",

Regards,
Simon


More information about the U-Boot mailing list