[PoC 070/241] global: Migrate CONFIG_KM_DEF_ENV to CFG

Tom Rini
2022-11-20T13:46:05Z

include/configs/km/keymile-common.h | 30 +++++++++++++-------------
include/configs/km/km-mpc83xx.h | 6 +++---
include/configs/km/km-powerpc.h | 2 +-
include/configs/km/pg-wcom-ls102xa.h | 8 +++----
include/configs/kmcent2.h | 8 +++----
include/configs/socfpga_arria5_secu1.h | 4 ++--
scripts/config_whitelist.txt | 14 ++++++------
7 files changed, 36 insertions(+), 36 deletions(-)

diff --git a/include/configs/km/keymile-common.h b/include/configs/km/keymile-common.h
index 94408e6efd9a..3d77b1770651 100644
--- a/include/configs/km/keymile-common.h
+++ b/include/configs/km/keymile-common.h
@@ -15,8 +15,8 @@

#define CFG_SYS_BAUDRATE_TABLE { 9600, 19200, 38400, 57600, 115200, 230400 }

-#ifndef CONFIG_KM_DEF_ENV_BOOTPARAMS
-#define CONFIG_KM_DEF_ENV_BOOTPARAMS \
+#ifndef CFG_KM_DEF_ENV_BOOTPARAMS
+#define CFG_KM_DEF_ENV_BOOTPARAMS \
"actual_bank=0\0"
#endif

@@ -65,7 +65,7 @@
* available targets:
* - 'release': for a standalone system kernel/rootfs from flash
*/
-#define CONFIG_KM_DEF_ENV_BOOTTARGETS \
+#define CFG_KM_DEF_ENV_BOOTTARGETS \
"subbootcmds=ubiattach ubicopy checkfdt cramfsloadfdt " \
"set_fdthigh cramfsloadkernel flashargs add_default " \
"addpanic boot\0" \
@@ -88,7 +88,7 @@
* - 'flashargs': defaults arguments for flash base boot
*
*/
-#define CONFIG_KM_DEF_ENV_BOOTARGS \
+#define CFG_KM_DEF_ENV_BOOTARGS \
"add_default=" \
"setenv bootargs ${bootargs} " \
"ip=${ipaddr}:${serverip}:${gatewayip}:${netmask}" \
@@ -120,7 +120,7 @@
* processor specific settings
* - 'cramfsloadfdt': copy fdt from a cramfs to ram
*/
-#define CONFIG_KM_DEF_ENV_FLASH_BOOT \
+#define CFG_KM_DEF_ENV_FLASH_BOOT \
"cramfsaddr=" __stringify(CONFIG_KM_CRAMFS_ADDR) "\0" \
"cramfsloadkernel=cramfsload ${load_addr_r} ${uimage}\0" \
"ubicopy=ubi read ${cramfsaddr} bootfs${boot_bank}\0" \
@@ -133,7 +133,7 @@
*
* - 'default': setup default environment
*/
-#define CONFIG_KM_DEF_ENV_CONSTANTS \
+#define CFG_KM_DEF_ENV_CONSTANTS \
"backup_bank=0\0" \
"release=run newenv; reset\0" \
"pnvramsize=" __stringify(CONFIG_KM_PNVRAM) "\0" \
@@ -142,15 +142,15 @@
"env_version=1\0" \
""

-#ifndef CONFIG_KM_DEF_ENV
-#define CONFIG_KM_DEF_ENV \
- CONFIG_KM_DEF_ENV_BOOTPARAMS \
+#ifndef CFG_KM_DEF_ENV
+#define CFG_KM_DEF_ENV \
+ CFG_KM_DEF_ENV_BOOTPARAMS \
"netdev=" __stringify(CONFIG_KM_DEF_NETDEV) "\0" \
- CONFIG_KM_DEF_ENV_CPU \
- CONFIG_KM_DEF_ENV_BOOTTARGETS \
- CONFIG_KM_DEF_ENV_BOOTARGS \
- CONFIG_KM_DEF_ENV_FLASH_BOOT \
- CONFIG_KM_DEF_ENV_CONSTANTS \
+ CFG_KM_DEF_ENV_CPU \
+ CFG_KM_DEF_ENV_BOOTTARGETS \
+ CFG_KM_DEF_ENV_BOOTARGS \
+ CFG_KM_DEF_ENV_FLASH_BOOT \
+ CFG_KM_DEF_ENV_CONSTANTS \
"altbootcmd=run bootcmd\0" \
"boot=bootm ${load_addr_r} - ${fdt_addr_r}\0" \
"bootcmd=km_checkbidhwk && " \
@@ -169,6 +169,6 @@
"load_addr_r=" __stringify(CONFIG_KM_KERNEL_ADDR) "\0" \
"load=tftpboot ${load_addr_r} ${u-boot}\0" \
""
-#endif /* CONFIG_KM_DEF_ENV */
+#endif /* CFG_KM_DEF_ENV */

#endif /* __CONFIG_KEYMILE_H */
diff --git a/include/configs/km/km-mpc83xx.h b/include/configs/km/km-mpc83xx.h
index 33655d144df1..3192ca7742a7 100644
--- a/include/configs/km/km-mpc83xx.h
+++ b/include/configs/km/km-mpc83xx.h
@@ -74,8 +74,8 @@
/*
* Environment Configuration
*/
-#ifndef CONFIG_KM_DEF_ENV /* if not set by keymile-common.h */
-#define CONFIG_KM_DEF_ENV "km-common=empty\0"
+#ifndef CFG_KM_DEF_ENV /* if not set by keymile-common.h */
+#define CFG_KM_DEF_ENV "km-common=empty\0"
#endif

#ifndef CFG_KM_DEF_ARCH
@@ -83,7 +83,7 @@
#endif

#define CFG_EXTRA_ENV_SETTINGS \
- CONFIG_KM_DEF_ENV \
+ CFG_KM_DEF_ENV \
CFG_KM_DEF_ARCH \
"newenv=" \
"prot off " __stringify(CONFIG_ENV_ADDR) " +0x40000 && " \
diff --git a/include/configs/km/km-powerpc.h b/include/configs/km/km-powerpc.h
index da0ee3f27e7e..73a224f790e1 100644
--- a/include/configs/km/km-powerpc.h
+++ b/include/configs/km/km-powerpc.h
@@ -30,7 +30,7 @@
/* architecture specific default bootargs */
#define CFG_KM_DEF_BOOT_ARGS_CPU ""

-#define CONFIG_KM_DEF_ENV_CPU \
+#define CFG_KM_DEF_ENV_CPU \
"u-boot="CFG_HOSTNAME "/u-boot.bin\0" \
"update=" \
"protect off " __stringify(BOOTFLASH_START) " +${filesize} && "\
diff --git a/include/configs/km/pg-wcom-ls102xa.h b/include/configs/km/pg-wcom-ls102xa.h
index 516fa76e3209..974486fc4c32 100644
--- a/include/configs/km/pg-wcom-ls102xa.h
+++ b/include/configs/km/pg-wcom-ls102xa.h
@@ -175,15 +175,15 @@
#define CFG_ENV_TOTAL_SIZE 0x40000
#define ENV_DEL_ADDR CONFIG_ENV_ADDR_REDUND /* direct for newenv */

-#ifndef CONFIG_KM_DEF_ENV /* if not set by keymile-common.h */
-#define CONFIG_KM_DEF_ENV
+#ifndef CFG_KM_DEF_ENV /* if not set by keymile-common.h */
+#define CFG_KM_DEF_ENV
#endif

#ifndef CFG_KM_DEF_BOOT_ARGS_CPU
#define CFG_KM_DEF_BOOT_ARGS_CPU ""
#endif

-#define CONFIG_KM_DEF_ENV_CPU \
+#define CFG_KM_DEF_ENV_CPU \
"boot=bootm ${load_addr_r} - ${fdt_addr_r}\0" \
"cramfsloadfdt=" \
"cramfsload ${fdt_addr_r} " \
@@ -224,7 +224,7 @@

#define CFG_EXTRA_ENV_SETTINGS \
CONFIG_KM_NEW_ENV \
- CONFIG_KM_DEF_ENV \
+ CFG_KM_DEF_ENV \
CFG_HW_ENV_SETTINGS \
"EEprom_ivm=pca9547:70:9\0" \
"ethrotate=no\0" \
diff --git a/include/configs/kmcent2.h b/include/configs/kmcent2.h
index 3c49e174d9a0..35ec79f7b7db 100644
--- a/include/configs/kmcent2.h
+++ b/include/configs/kmcent2.h
@@ -390,13 +390,13 @@ int get_scl(void);
/*
* Environment Configuration
*/
-#ifndef CONFIG_KM_DEF_ENV /* if not set by keymile-common.h */
-#define CONFIG_KM_DEF_ENV
+#ifndef CFG_KM_DEF_ENV /* if not set by keymile-common.h */
+#define CFG_KM_DEF_ENV
#endif

#define __USB_PHY_TYPE utmi

-#define CONFIG_KM_DEF_ENV_CPU \
+#define CFG_KM_DEF_ENV_CPU \
"boot=bootm ${load_addr_r} - ${fdt_addr_r}\0" \
"cramfsloadfdt=" \
"cramfsload ${fdt_addr_r} " \
@@ -442,7 +442,7 @@ int get_scl(void);
#endif

#define CFG_EXTRA_ENV_SETTINGS \
- CONFIG_KM_DEF_ENV \
+ CFG_KM_DEF_ENV \
CFG_KM_DEF_ARCH \
CONFIG_KM_NEW_ENV \
CFG_HW_ENV_SETTINGS \
diff --git a/include/configs/socfpga_arria5_secu1.h b/include/configs/socfpga_arria5_secu1.h
index f12163ccc990..71aa5a7ca949 100644
--- a/include/configs/socfpga_arria5_secu1.h
+++ b/include/configs/socfpga_arria5_secu1.h
@@ -46,7 +46,7 @@
"newenv=" \
"nand erase 0x100000 0x40000\0"

-#define CONFIG_KM_DEF_ENV_BOOTTARGETS \
+#define CFG_KM_DEF_ENV_BOOTTARGETS \
"release=" \
"run newenv; reset\0" \
"develop=" \
@@ -54,7 +54,7 @@

#define CFG_EXTRA_ENV_SETTINGS \
FPGA_RMTU_ENV \
- CONFIG_KM_DEF_ENV_BOOTTARGETS \
+ CFG_KM_DEF_ENV_BOOTTARGETS \
CONFIG_KM_NEW_ENV \
"socfpga_legacy_reset_compat=1\0" \
"altbootcmd=run bootcmd;\0" \
diff --git a/scripts/config_whitelist.txt b/scripts/config_whitelist.txt
index d203ede8c963..d5909de8762e 100644
--- a/scripts/config_whitelist.txt
+++ b/scripts/config_whitelist.txt
@@ -72,13 +72,13 @@ CFG_IRAM_SIZE
CFG_IRAM_TOP
CFG_KM_DEF_ARCH
CFG_KM_DEF_BOOT_ARGS_CPU
-CONFIG_KM_DEF_ENV
-CONFIG_KM_DEF_ENV_BOOTARGS
-CONFIG_KM_DEF_ENV_BOOTPARAMS
-CONFIG_KM_DEF_ENV_BOOTTARGETS
-CONFIG_KM_DEF_ENV_CONSTANTS
-CONFIG_KM_DEF_ENV_CPU
-CONFIG_KM_DEF_ENV_FLASH_BOOT
+CFG_KM_DEF_ENV
+CFG_KM_DEF_ENV_BOOTARGS
+CFG_KM_DEF_ENV_BOOTPARAMS
+CFG_KM_DEF_ENV_BOOTTARGETS
+CFG_KM_DEF_ENV_CONSTANTS
+CFG_KM_DEF_ENV_CPU
+CFG_KM_DEF_ENV_FLASH_BOOT
CONFIG_KM_DEV_ENV_FLASH_BOOT_UBI
CONFIG_KM_ECC_MODE
CONFIG_KM_NEW_ENV
--
2.25.1