mbox series

[0/7] smbios: missing strings, RISC-V processor ID

Message ID 20240129210453.31070-1-heinrich.schuchardt@canonical.com
Headers show
Series smbios: missing strings, RISC-V processor ID | expand

Message

Heinrich Schuchardt Jan. 29, 2024, 9:04 p.m. UTC
When a string value cannot be provided we should not create a string
'Unknown' but just set the string index to 0 as suggested by the
SMBIOS specification. Program dmidecode will render this as
'Not Specified'.

Set the chassis handle in the type 2 structure.

In the type 4 structure fill the RISC-V SMBIOS Processor ID.

Correct the output formatting of the smbios command:

* Add a missing colon after UUID.
* Format handle references consistently.
* Render missing strings as 'Not Specified'.

Heinrich Schuchardt (7):
  cmd: smbios: always use '0x%04x' for printing handles
  cmd: smbios: add missing colon after UUID
  cmd: smbios: replace missing string by 'Not Specified'
  smbios: string table always needs two terminating NUL bytes
  smbios: if a string value is unknown, use string number 0
  smbios: provide type 4 RISC-V SMBIOS Processor ID
  smbios: correctly fill chassis handle

 cmd/smbios.c            | 12 ++++++++----
 drivers/cpu/riscv_cpu.c | 12 ++++++++++++
 lib/smbios.c            | 38 +++++++++++++++++++++++---------------
 3 files changed, 43 insertions(+), 19 deletions(-)