The phyCORE-i.MX 93 is available in various variants (e.g. different ram sizes, eMMC HS400 yes/no). It's eeprom contains information which features the existing module supports.
Extend the existing board-code to support all the SOM variants. The spl/u-boot evaluates the eeprom information and enables supported features accordingly. The resulting spl and u-boot binary is able to boot each phyCORE-i.MX 93 SOM variant on each carrier board. Changes in v3: patch #1: - none changes patch #2: - remove unwanted dts node eepromid - correct typo in doc (PHYTEC_IMX93_VOLTAGE_3V3) - improve enum code-style (phytec_imx93_option_index) patch #3: - add comment about SoM-scope to imx93-phyboard-segin-u-boot.dtsi - rebase to the latest master - adapt doc according to new defconfig Changes in v2: patch #1: - remove multiple blank lines - add update of 1GB ram timings to commit message patch #2: - encapsulate handling of feature flag VOLTAGE into own function - move definition of enum phytec_imx93_ddr_eeprom_code into header file patch #3: - just rename imx93-phyboard-segin_defconfig and add needed CONFIGs, instead of creating an entirely new second defconfig - remove wrong comment from imx93-phyboard-segin-u-boot.dtsi - improve commit message Christoph Stoidner (3): board: phytec: phycore-imx93: Add 2GB LPDDR4X RAM timings board: phytec: imx93: Add eeprom-based hardware introspection board: phytec: imx93: Add phyCORE-i.MX 93 support for all SOM variants arch/arm/dts/imx93-phyboard-segin-u-boot.dtsi | 20 +- arch/arm/mach-imx/imx9/Kconfig | 2 + arch/arm/mach-imx/imx9/soc.c | 2 +- board/phytec/common/Kconfig | 8 + board/phytec/common/Makefile | 1 + board/phytec/common/imx93_som_detection.c | 111 +++ board/phytec/common/imx93_som_detection.h | 51 ++ board/phytec/phycore_imx93/Kconfig | 28 + board/phytec/phycore_imx93/MAINTAINERS | 7 +- board/phytec/phycore_imx93/lpddr4_timing.c | 793 ++++++++++++++++-- board/phytec/phycore_imx93/phycore-imx93.c | 51 ++ board/phytec/phycore_imx93/spl.c | 48 ++ ...egin_defconfig => imx93-phycore_defconfig} | 2 + ...3-phyboard-segin.rst => imx93-phycore.rst} | 8 +- doc/board/phytec/index.rst | 2 +- 15 files changed, 1063 insertions(+), 71 deletions(-) create mode 100644 board/phytec/common/imx93_som_detection.c create mode 100644 board/phytec/common/imx93_som_detection.h rename configs/{imx93-phyboard-segin_defconfig => imx93-phycore_defconfig} (98%) rename doc/board/phytec/{imx93-phyboard-segin.rst => imx93-phycore.rst} (91%) -- 2.34.1