]> git.baikalelectronics.ru Git - uboot.git/commitdiff
arm: dts: iot2050: Use the auto generator nodes for fdt
authorSu Baocheng <baocheng.su@siemens.com>
Tue, 28 Feb 2023 18:19:10 +0000 (19:19 +0100)
committerTom Rini <trini@konsulko.com>
Wed, 29 Mar 2023 15:58:26 +0000 (11:58 -0400)
Refactor according to the entry `fit: Entry containing a FIT` of
document tools/binman/README.entries.

As the generator uses the device tree name for the config description,
board_fit_config_name_match requires a small adjustment as well.

Signed-off-by: Su Baocheng <baocheng.su@siemens.com>
[Jan: re-add now required CONFIG_OF_LIST, update config matching]
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
arch/arm/dts/k3-am65-iot2050-boot-image.dtsi
board/siemens/iot2050/board.c
configs/iot2050_pg1_defconfig
configs/iot2050_pg2_defconfig

index 3135ad047151b629a0aa729dede717157266c22d..4666957686464c30a4fbbeeb780a7836b3d8f004 100644 (file)
@@ -32,6 +32,7 @@
 
                fit@0x280000 {
                        description = "U-Boot for IOT2050";
+                       fit,fdt-list = "of-list";
                        offset = <0x280000>;
                        images {
                                u-boot {
                                        };
                                };
 
-                               fdt-iot2050-basic {
-                                       description = "k3-am6528-iot2050-basic*.dtb";
+                               @fdt-SEQ {
+                                       description = "fdt-NAME";
                                        type = "flat_dt";
                                        arch = "arm64";
                                        compression = "none";
-                                       blob {
-#ifdef CONFIG_TARGET_IOT2050_A53_PG1
-                                               filename = "arch/arm/dts/k3-am6528-iot2050-basic.dtb";
-#else
-                                               filename = "arch/arm/dts/k3-am6528-iot2050-basic-pg2.dtb";
-#endif
-                                       };
-                               };
-
-                               fdt-iot2050-advanced {
-                                       description = "k3-am6548-iot2050-advanced*.dtb";
-                                       type = "flat_dt";
-                                       arch = "arm64";
-                                       compression = "none";
-                                       blob {
-#ifdef CONFIG_TARGET_IOT2050_A53_PG1
-                                               filename = "arch/arm/dts/k3-am6548-iot2050-advanced.dtb";
-#else
-                                               filename = "arch/arm/dts/k3-am6548-iot2050-advanced-pg2.dtb";
-#endif
-                                       };
                                };
 
 #ifdef CONFIG_WDT_K3_RTI_FW_FILE
                        };
 
                        configurations {
-                               default = "conf-iot2050-basic";
-
-                               conf-iot2050-basic {
-                                       description = "iot2050-basic";
-                                       firmware = "u-boot";
-                                       fdt = "fdt-iot2050-basic";
-#ifdef CONFIG_WDT_K3_RTI_FW_FILE
-                                       loadables = "k3-rti-wdt-firmware";
-#endif
-                               };
-
-                               conf-iot2050-advanced {
-                                       description = "iot2050-advanced";
+                               default = "@config-DEFAULT-SEQ";
+                               @config-SEQ {
+                                       description = "NAME";
                                        firmware = "u-boot";
-                                       fdt = "fdt-iot2050-advanced";
+                                       fdt = "fdt-SEQ";
 #ifdef CONFIG_WDT_K3_RTI_FW_FILE
                                        loadables = "k3-rti-wdt-firmware";
 #endif
index dbf893000a7d4010a6f7b0bef3acf77110c6309a..57d7009e8c7f57c1a112804b3077a63d48844828 100644 (file)
@@ -154,6 +154,9 @@ int board_fit_config_name_match(const char *name)
        struct iot2050_info *info = IOT2050_INFO_DATA;
        char upper_name[32];
 
+       /* skip the prefix "k3-am65x8-" */
+       name += 10;
+
        if (info->magic != IOT2050_INFO_MAGIC ||
            strlen(name) >= sizeof(upper_name))
                return -1;
index 0440cf1c008113e5c6f1a3b711e8f63e2b71358b..579971c39cd5ea263b7df45124d675694596937c 100644 (file)
@@ -69,6 +69,7 @@ CONFIG_CMD_TIME=y
 # CONFIG_ISO_PARTITION is not set
 CONFIG_OF_CONTROL=y
 CONFIG_SPL_OF_CONTROL=y
+CONFIG_OF_LIST="k3-am6528-iot2050-basic k3-am6548-iot2050-advanced"
 CONFIG_SPL_MULTI_DTB_FIT=y
 CONFIG_SPL_OF_LIST="k3-am65-iot2050-spl"
 CONFIG_SPL_MULTI_DTB_FIT_NO_COMPRESSION=y
index 58aefac83010e5e672d2d0710e2a8aca8ec3f531..65400b4696ae6dd9069967413db41bbf578b5fda 100644 (file)
@@ -71,6 +71,7 @@ CONFIG_CMD_TIME=y
 # CONFIG_ISO_PARTITION is not set
 CONFIG_OF_CONTROL=y
 CONFIG_SPL_OF_CONTROL=y
+CONFIG_OF_LIST="k3-am6528-iot2050-basic-pg2 k3-am6548-iot2050-advanced-pg2"
 CONFIG_SPL_MULTI_DTB_FIT=y
 CONFIG_SPL_OF_LIST="k3-am65-iot2050-spl"
 CONFIG_SPL_MULTI_DTB_FIT_NO_COMPRESSION=y