[PATCH v4 00/13] x86: Updates to SMBIOS

Simon Glass sjg at chromium.org
Thu Oct 22 16:19:35 CEST 2020


At present there are a few Kconfig options which allow SMBIOS fields to
be specified at build time.

Not all fields are supported. Also, defining these at build-time is
limiting since a factory system cannot insert values for particular boards
or models without rebuilding U-Boot.

This series adds a way to set SMBIOS properties using the devicetree.
With this approach, more fields are supported and it is easy to update
values in the devicetree in the factory.

It also updates existing boards to use devicetree and drops the CONFIG
options, using a new default sysinfo driver.

Changes in v4:
- Fix build error with vexpress_ca9x4

Changes in v3:
- Use a different binding with subnodes for each table type
- Add onto the sysinfo binding

Changes in v2:
- Move dm.h header file to avoid build error on qemu-arm
- Deal with boards that don't use of-control

Simon Glass (13):
  board: Rename uclass to sysinfo
  doc: Add a binding for sysinfo
  x86: Pass an ofnode into each SMBIOS function
  smbios: Allow properties to come from the device tree
  smbios: Add more properties
  smbios: Add documentation and devicetree binding
  sysinfo: Provide a default driver to set SMBIOS values
  rockchip: Use devicetree for SMBIOS settings
  imx: Use devicetree for SMBIOS settings on MYiR MYS-6ULX
  odroid-c2: Use devicetree for SMBIOS settings
  arm64: mvebu: Use devicetree for SMBIOS settings on uDPU
  x86: galileo: Use devicetree for SMBIOS settings
  smbios: Drop the unused Kconfig options

 arch/arm/dts/armada-3720-uDPU-u-boot.dtsi     |  20 +++
 .../dts/imx6ull-myir-mys-6ulx-eval-u-boot.dts |  25 ++++
 arch/arm/dts/meson-gxbb-odroidc2-u-boot.dtsi  |  23 +++
 arch/arm/dts/rk3328-roc-cc-u-boot.dtsi        |  21 +++
 arch/arm/dts/rk3328-rock-pi-e-u-boot.dtsi     |  23 +++
 arch/arm/dts/rk3328-rock64-u-boot.dtsi        |  21 +++
 arch/arm/dts/rk3368-lion-u-boot.dtsi          |  20 +++
 arch/powerpc/dts/gdsys/gazerbeam-uboot.dtsi   |   2 +-
 arch/sandbox/dts/test.dts                     |   8 +-
 arch/x86/dts/galileo.dts                      |  18 +++
 board/gdsys/common/cmd_ioloop.c               |  12 +-
 board/gdsys/mpc8308/gazerbeam.c               |  47 ++++---
 board/google/chromebook_coral/coral.c         |   2 +-
 board/intel/galileo/Kconfig                   |  11 --
 common/spl/spl_fit.c                          |  15 +-
 configs/chromebook_coral_defconfig            |   2 +-
 configs/clearfog_gt_8k_defconfig              |   2 -
 configs/gazerbeam_defconfig                   |   4 +-
 configs/lion-rk3368_defconfig                 |   4 +-
 configs/mt7622_rfb_defconfig                  |   1 -
 configs/mvebu_db_armada8k_defconfig           |   2 -
 configs/myir_mys_6ulx_defconfig               |   3 +-
 configs/odroid-c2_defconfig                   |   4 +-
 configs/r8a774a1_beacon_defconfig             |   2 -
 configs/r8a77970_eagle_defconfig              |   2 -
 configs/r8a77980_condor_defconfig             |   2 -
 configs/r8a77990_ebisu_defconfig              |   2 -
 configs/r8a77995_draak_defconfig              |   2 -
 configs/rcar3_salvator-x_defconfig            |   2 -
 configs/rcar3_ulcb_defconfig                  |   2 -
 configs/roc-cc-rk3328_defconfig               |   4 +-
 configs/rock-pi-e-rk3328_defconfig            |   4 +-
 configs/rock64-rk3328_defconfig               |   4 +-
 configs/sandbox64_defconfig                   |   8 +-
 configs/sandbox_defconfig                     |   8 +-
 configs/sandbox_flattree_defconfig            |   4 +-
 configs/sandbox_spl_defconfig                 |   4 +-
 configs/uDPU_defconfig                        |   3 +-
 doc/arch/x86.rst                              |   8 ++
 .../gdsys,sysinfo_gazerbeam.txt}              |   8 +-
 doc/device-tree-bindings/sysinfo/smbios.txt   |  77 ++++++++++
 doc/device-tree-bindings/sysinfo/sysinfo.txt  |  18 +++
 drivers/Kconfig                               |   4 +-
 drivers/Makefile                              |   2 +-
 drivers/board/Kconfig                         |  25 ----
 drivers/board/Makefile                        |   7 -
 drivers/board/board-uclass.c                  |  71 ----------
 drivers/sysinfo/Kconfig                       |  33 +++++
 drivers/sysinfo/Makefile                      |   8 ++
 drivers/{board => sysinfo}/gazerbeam.c        |  74 +++++-----
 drivers/{board => sysinfo}/gazerbeam.h        |   0
 drivers/{board => sysinfo}/sandbox.c          |  50 +++----
 drivers/{board => sysinfo}/sandbox.h          |   0
 drivers/sysinfo/smbios.c                      |  24 ++++
 drivers/sysinfo/sysinfo-uclass.c              |  71 ++++++++++
 drivers/timer/mpc83xx_timer.c                 |  10 +-
 include/dm/uclass-id.h                        |   2 +-
 include/smbios.h                              |   5 +-
 include/{board.h => sysinfo.h}                |  80 +++++------
 lib/Kconfig                                   |  17 +--
 lib/smbios.c                                  | 133 +++++++++++++-----
 test/dm/Makefile                              |   2 +-
 test/dm/board.c                               |  59 --------
 test/dm/sysinfo.c                             |  59 ++++++++
 64 files changed, 767 insertions(+), 423 deletions(-)
 create mode 100644 arch/arm/dts/imx6ull-myir-mys-6ulx-eval-u-boot.dts
 rename doc/device-tree-bindings/{board/gdsys,board_gazerbeam.txt => sysinfo/gdsys,sysinfo_gazerbeam.txt} (90%)
 create mode 100644 doc/device-tree-bindings/sysinfo/smbios.txt
 create mode 100644 doc/device-tree-bindings/sysinfo/sysinfo.txt
 delete mode 100644 drivers/board/Kconfig
 delete mode 100644 drivers/board/Makefile
 delete mode 100644 drivers/board/board-uclass.c
 create mode 100644 drivers/sysinfo/Kconfig
 create mode 100644 drivers/sysinfo/Makefile
 rename drivers/{board => sysinfo}/gazerbeam.c (69%)
 rename drivers/{board => sysinfo}/gazerbeam.h (100%)
 rename drivers/{board => sysinfo}/sandbox.c (50%)
 rename drivers/{board => sysinfo}/sandbox.h (100%)
 create mode 100644 drivers/sysinfo/smbios.c
 create mode 100644 drivers/sysinfo/sysinfo-uclass.c
 rename include/{board.h => sysinfo.h} (65%)
 delete mode 100644 test/dm/board.c
 create mode 100644 test/dm/sysinfo.c

-- 
2.29.0.rc1.297.gfa9743e501-goog



More information about the U-Boot mailing list