Skip to contentSkip to conversation

aristainetos2: Rename CONFIG_EXTRA_ENV_BOARD_SETTINGS

PATCH In review Tom Rini 3 participants 8 messages Aug 10, 2021 – Aug 30, 2021 Arm Samsung Exynos

lore
Share & tools
lore

Tom Rini

author
#0 lore raw

PATCH 1/3 aristainetos2: Rename CONFIG_EXTRA_ENV_BOARD_SETTINGS

Rename CONFIG_EXTRA_ENV_BOARD_SETTINGS to EXTRA_ENV_BOARD_SETTINGS in order to not further add to the CONFIG namespace.

Cc Heiko Schocher <[email protected]>
---
 include/configs/aristainetos2.h | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
include/configs/aristainetos2.h +3 -3
index 78fa1a969e7f..69398787d9e7 100644
@@ -93,13 +93,13 @@
 #endif
 
 #if (CONFIG_SYS_BOARD_VERSION == 5)
-#define CONFIG_EXTRA_ENV_BOARD_SETTINGS \
+#define EXTRA_ENV_BOARD_SETTINGS \
 	"dead=while true; do; " \
 		"led led_red on; sleep 1;" \
 		"led led_red off; sleep 1;" \
 	"done\0"
 #elif (CONFIG_SYS_BOARD_VERSION == 6)
-#define CONFIG_EXTRA_ENV_BOARD_SETTINGS \
+#define EXTRA_ENV_BOARD_SETTINGS \
 	"dead=while true; do; " \
 		"led led_red on; led led_red2 on; sleep 1;" \
 		"led led_red off; led led_red2 off;; sleep 1;" \
@@ -414,7 +414,7 @@
 		"run main_rescue_boot;" \
 	"fi; \0"\
 	HAB_EXTRA_SETTINGS \
-	CONFIG_EXTRA_ENV_BOARD_SETTINGS
+	EXTRA_ENV_BOARD_SETTINGS
 
 #define CONFIG_ARP_TIMEOUT		200UL
 
Signature · 1 line
2.17.1
author
#1 lore raw

PATCH 2/3 arm: keystone2: Rename CONFIG_ENV_KS2_BOARD_SETTINGS

Rename CONFIG_ENV_KS2_BOARD_SETTINGS to ENV_KS2_BOARD_SETTINGS so that it better fits with the rest of the environment addition macros.

Cc Vitaly Andrianov <[email protected]>
---
 include/configs/k2e_evm.h            | 2 +-
 include/configs/k2g_evm.h            | 2 +-
 include/configs/k2hk_evm.h           | 2 +-
 include/configs/k2l_evm.h            | 2 +-
 include/configs/ti_armv7_keystone2.h | 2 +-
 5 files changed, 5 insertions(+), 5 deletions(-)
include/configs/k2e_evm.h +1 -1
index 716ae3b0d4aa..65bf646f3fb2 100644
@@ -23,7 +23,7 @@
 #endif
 
 /* U-Boot general configuration */
-#define CONFIG_EXTRA_ENV_KS2_BOARD_SETTINGS				\
+#define ENV_KS2_BOARD_SETTINGS						\
 	DEFAULT_FW_INITRAMFS_BOOT_ENV					\
 	DEFAULT_SEC_BOOT_ENV						\
 	"boot=ubi\0"							\
include/configs/k2g_evm.h +1 -1
index 4471eb4f6a84..17245ab15861 100644
@@ -16,7 +16,7 @@
 #define CONFIG_SOC_K2G
 
 /* U-Boot general configuration */
-#define CONFIG_EXTRA_ENV_KS2_BOARD_SETTINGS				\
+#define ENV_KS2_BOARD_SETTINGS						\
 	DEFAULT_MMC_TI_ARGS						\
 	DEFAULT_PMMC_BOOT_ENV						\
 	DEFAULT_FW_INITRAMFS_BOOT_ENV					\
include/configs/k2hk_evm.h +1 -1
index d90b2648185a..1fdecd60e769 100644
@@ -23,7 +23,7 @@
 #endif
 
 /* U-Boot general configuration */
-#define CONFIG_EXTRA_ENV_KS2_BOARD_SETTINGS				\
+#define ENV_KS2_BOARD_SETTINGS						\
 	DEFAULT_FW_INITRAMFS_BOOT_ENV					\
 	DEFAULT_SEC_BOOT_ENV						\
 	"boot=ubi\0"							\
include/configs/k2l_evm.h +1 -1
index 152cea01b55b..97512c9903de 100644
@@ -23,7 +23,7 @@
 #endif
 
 /* U-Boot general configuration */
-#define CONFIG_EXTRA_ENV_KS2_BOARD_SETTINGS				\
+#define ENV_KS2_BOARD_SETTINGS						\
 	DEFAULT_FW_INITRAMFS_BOOT_ENV					\
 	DEFAULT_SEC_BOOT_ENV						\
 	"boot=ubi\0"							\
include/configs/ti_armv7_keystone2.h +1 -1
index cfc2be7b9f07..fc2b3431ddba 100644
@@ -187,7 +187,7 @@
 
 #define CONFIG_EXTRA_ENV_SETTINGS					\
 	DEFAULT_LINUX_BOOT_ENV						\
-	CONFIG_EXTRA_ENV_KS2_BOARD_SETTINGS				\
+	ENV_KS2_BOARD_SETTINGS						\
 	DFUARGS								\
 	"bootdir=/boot\0" \
 	"tftp_root=/\0"							\
Signature · 1 line
2.17.1
author
#2 lore raw

Re: [PATCH 2/3] arm: keystone2: Rename CONFIG_ENV_KS2_BOARD_SETTINGS

Quoted 5 lines · Tom Rini

Rename CONFIG_ENV_KS2_BOARD_SETTINGS to ENV_KS2_BOARD_SETTINGS so that it better fits with the rest of the environment addition macros.

Cc Vitaly Andrianov <[email protected]>

Applied to u-boot/next, thanks!

Signature · 1 line
Tom
author
#3 lore raw

PATCH 3/3 exynos: Update environment macros a bit

In reply to Tom Rini

Rework the default environment a bit to not use non-standard CONFIG_ENV_... names and similar one-off CONFIG names.

Cc Jaehoon Chung <[email protected]>
---
 include/configs/exynos4-common.h    |  2 +-
 include/configs/s5pc210_universal.h | 26 +++++++++-----------------
 include/configs/trats.h             |  9 +++------
 include/configs/trats2.h            |  2 +-
 4 files changed, 14 insertions(+), 25 deletions(-)
include/configs/exynos4-common.h +1 -1
index 5e2aca371e7e..2ca14d0b86e3 100644
@@ -32,7 +32,7 @@
 #define CONFIG_USB_GADGET_DWC2_OTG_PHY
 
 /* Common environment variables */
-#define CONFIG_EXTRA_ENV_ITB \
+#define ENV_ITB \
 	"loadkernel=load mmc ${mmcbootdev}:${mmcbootpart} ${kerneladdr} " \
 		"${kernelname}\0" \
 	"loadinitrd=load mmc ${mmcbootdev}:${mmcbootpart} ${initrdaddr} " \
include/configs/s5pc210_universal.h +9 -17
index 0b679f437482..8ee667e69306 100644
@@ -44,16 +44,6 @@
 				",100M(swap)"\
 				",-(UMS)\0"
 
-#define CONFIG_ENV_UBI_MTD	" ubi.mtd=${ubiblock} ubi.mtd=4 ubi.mtd=7"
-#define CONFIG_BOOTBLOCK	"10"
-#define CONFIG_UBIBLOCK		"9"
-
-#define CONFIG_ENV_UBIFS_OPTION	" rootflags=bulk_read,no_chk_data_crc "
-#define CONFIG_ENV_FLASHBOOT	CONFIG_ENV_UBI_MTD CONFIG_ENV_UBIFS_OPTION \
-				"${mtdparts}"
-
-#define CONFIG_ENV_COMMON_BOOT	"${console} ${meminfo}"
-
 #define CONFIG_EXTRA_ENV_SETTINGS					\
 	"updateb=" \
 		"onenand erase 0x0 0x100000;" \
@@ -71,18 +61,20 @@
 	"lpj=lpj=3981312\0" \
 	"ubifsboot=" \
 		"set bootargs root=ubi0!rootfs rootfstype=ubifs ${lpj} " \
-		CONFIG_ENV_FLASHBOOT " ${opts} ${lcdinfo} " \
-		CONFIG_ENV_COMMON_BOOT "; run bootk\0" \
+		"ubi.mtd=${ubiblock} ubi.mtd=4 ubi.mtd=7 " \
+		"rootflags=bulk_read,no_chk_data_crc ${mtdparts} ${opts} " \
+		"${lcdinfo} ${console} ${meminfo}; run bootk\0" \
 	"tftpboot=" \
 		"set bootargs root=ubi0!rootfs rootfstype=ubifs " \
-		CONFIG_ENV_FLASHBOOT " ${opts} ${lcdinfo} " \
-		CONFIG_ENV_COMMON_BOOT \
+		"ubi.mtd=${ubiblock} ubi.mtd=4 ubi.mtd=7 " \
+		"rootflags=bulk_read,no_chk_data_crc ${mtdparts} ${opts} " \
+		"${lcdinfo} ${console} ${meminfo}" \
 		"; tftp 0x40007FC0 uImage; bootm 0x40007FC0\0" \
 	"nfsboot=" \
 		"set bootargs root=/dev/nfs rw " \
 		"nfsroot=${nfsroot},nolock,tcp " \
 		"ip=${ipaddr}:${serverip}:${gatewayip}:" \
-		"${netmask}:generic:usb0:off " CONFIG_ENV_COMMON_BOOT \
+		"${netmask}:generic:usb0:off ${console} ${meminfo}" \
 		"; run bootk\0" \
 	"ramfsboot=" \
 		"set bootargs root=/dev/ram0 rw rootfstype=ext2 " \
@@ -102,8 +94,8 @@
 	"mbrparts=" MBRPARTS_DEFAULT \
 	"meminfo=crashkernel=32M@0x50000000\0" \
 	"nfsroot=/nfsroot/arm\0" \
-	"bootblock=" CONFIG_BOOTBLOCK "\0" \
-	"ubiblock=" CONFIG_UBIBLOCK" \0" \
+	"bootblock=10\0" \
+	"ubiblock=9\0" \
 	"ubi=enabled\0" \
 	"loaduimage=fatload mmc ${mmcdev}:${mmcbootpart} 0x40007FC0 uImage\0" \
 	"mmcdev=0\0" \
include/configs/trats.h +3 -6
index a44792d85764..c3f891ae53d8 100644
@@ -40,9 +40,6 @@
 
 #define CONFIG_SYS_MONITOR_BASE	0x00000000
 
-#define CONFIG_BOOTBLOCK		"10"
-#define CONFIG_ENV_COMMON_BOOT		"${console} ${meminfo}"
-
 /* Tizen - partitions definitions */
 #define PARTS_CSA		"csa-mmc"
 #define PARTS_BOOT		"boot"
@@ -94,7 +91,7 @@
 		"setenv bootargs root=/dev/nfs rw " \
 		"nfsroot=${nfsroot},nolock,tcp " \
 		"ip=${ipaddr}:${serverip}:${gatewayip}:" \
-		"${netmask}:generic:usb0:off " CONFIG_ENV_COMMON_BOOT \
+		"${netmask}:generic:usb0:off ${console} ${meminfo}" \
 		"; run bootk\0" \
 	"ramfsboot=" \
 		"setenv bootargs root=/dev/ram0 rw rootfstype=ext2 " \
@@ -112,7 +109,7 @@
 	"console=console=ttySAC2,115200n8\0" \
 	"meminfo=crashkernel=32M@0x50000000\0" \
 	"nfsroot=/nfsroot/arm\0" \
-	"bootblock=" CONFIG_BOOTBLOCK "\0" \
+	"bootblock=10\0" \
 	"loaduimage=ext4load mmc ${mmcdev}:${mmcbootpart} 0x40007FC0 uImage\0" \
 	"loaddtb=ext4load mmc ${mmcdev}:${mmcbootpart} ${fdtaddr} " \
 		"${fdtfile}\0" \
@@ -141,7 +138,7 @@
 		   "setenv spl_imgsize;" \
 		   "setenv spl_imgaddr;" \
 		   "setenv spl_addr_tmp;\0" \
-	CONFIG_EXTRA_ENV_ITB \
+	ENV_ITB \
 	"fdtaddr=40800000\0" \
 
 /* Falcon mode definitions */
include/configs/trats2.h +1 -1
index 4b1eff08f3b3..e5f2b0cc993a 100644
@@ -125,7 +125,7 @@
 		   "setenv spl_imgsize;" \
 		   "setenv spl_imgaddr;" \
 		   "setenv spl_addr_tmp;\0" \
-	CONFIG_EXTRA_ENV_ITB \
+	ENV_ITB \
 	"fdtaddr=40800000\0" \
 
 /* GPT */
Signature · 1 line
2.17.1
Reviewed-by on v1 3/3
#4 lore raw

Re: [PATCH 3/3] exynos: Update environment macros a bit

Quoted 5 lines · Tom Rini

Rework the default environment a bit to not use non-standard CONFIG_ENV_... names and similar one-off CONFIG names.

Cc Jaehoon Chung <[email protected]>

Best Regars,
Jaehoon Chung

Quoted 133 lines
---
 include/configs/exynos4-common.h    |  2 +-
 include/configs/s5pc210_universal.h | 26 +++++++++-----------------
 include/configs/trats.h             |  9 +++------
 include/configs/trats2.h            |  2 +-
 4 files changed, 14 insertions(+), 25 deletions(-)
include/configs/exynos4-common.h +1 -1
index 5e2aca371e7e..2ca14d0b86e3 100644
@@ -32,7 +32,7 @@
 #define CONFIG_USB_GADGET_DWC2_OTG_PHY
 
 /* Common environment variables */
-#define CONFIG_EXTRA_ENV_ITB \
+#define ENV_ITB \
 	"loadkernel=load mmc ${mmcbootdev}:${mmcbootpart} ${kerneladdr} " \
 		"${kernelname}\0" \
 	"loadinitrd=load mmc ${mmcbootdev}:${mmcbootpart} ${initrdaddr} " \
include/configs/s5pc210_universal.h +9 -17
index 0b679f437482..8ee667e69306 100644
@@ -44,16 +44,6 @@
 				",100M(swap)"\
 				",-(UMS)\0"
 
-#define CONFIG_ENV_UBI_MTD	" ubi.mtd=${ubiblock} ubi.mtd=4 ubi.mtd=7"
-#define CONFIG_BOOTBLOCK	"10"
-#define CONFIG_UBIBLOCK		"9"
-
-#define CONFIG_ENV_UBIFS_OPTION	" rootflags=bulk_read,no_chk_data_crc "
-#define CONFIG_ENV_FLASHBOOT	CONFIG_ENV_UBI_MTD CONFIG_ENV_UBIFS_OPTION \
-				"${mtdparts}"
-
-#define CONFIG_ENV_COMMON_BOOT	"${console} ${meminfo}"
-
 #define CONFIG_EXTRA_ENV_SETTINGS					\
 	"updateb=" \
 		"onenand erase 0x0 0x100000;" \
@@ -71,18 +61,20 @@
 	"lpj=lpj=3981312\0" \
 	"ubifsboot=" \
 		"set bootargs root=ubi0!rootfs rootfstype=ubifs ${lpj} " \
-		CONFIG_ENV_FLASHBOOT " ${opts} ${lcdinfo} " \
-		CONFIG_ENV_COMMON_BOOT "; run bootk\0" \
+		"ubi.mtd=${ubiblock} ubi.mtd=4 ubi.mtd=7 " \
+		"rootflags=bulk_read,no_chk_data_crc ${mtdparts} ${opts} " \
+		"${lcdinfo} ${console} ${meminfo}; run bootk\0" \
 	"tftpboot=" \
 		"set bootargs root=ubi0!rootfs rootfstype=ubifs " \
-		CONFIG_ENV_FLASHBOOT " ${opts} ${lcdinfo} " \
-		CONFIG_ENV_COMMON_BOOT \
+		"ubi.mtd=${ubiblock} ubi.mtd=4 ubi.mtd=7 " \
+		"rootflags=bulk_read,no_chk_data_crc ${mtdparts} ${opts} " \
+		"${lcdinfo} ${console} ${meminfo}" \
 		"; tftp 0x40007FC0 uImage; bootm 0x40007FC0\0" \
 	"nfsboot=" \
 		"set bootargs root=/dev/nfs rw " \
 		"nfsroot=${nfsroot},nolock,tcp " \
 		"ip=${ipaddr}:${serverip}:${gatewayip}:" \
-		"${netmask}:generic:usb0:off " CONFIG_ENV_COMMON_BOOT \
+		"${netmask}:generic:usb0:off ${console} ${meminfo}" \
 		"; run bootk\0" \
 	"ramfsboot=" \
 		"set bootargs root=/dev/ram0 rw rootfstype=ext2 " \
@@ -102,8 +94,8 @@
 	"mbrparts=" MBRPARTS_DEFAULT \
 	"meminfo=crashkernel=32M@0x50000000\0" \
 	"nfsroot=/nfsroot/arm\0" \
-	"bootblock=" CONFIG_BOOTBLOCK "\0" \
-	"ubiblock=" CONFIG_UBIBLOCK" \0" \
+	"bootblock=10\0" \
+	"ubiblock=9\0" \
 	"ubi=enabled\0" \
 	"loaduimage=fatload mmc ${mmcdev}:${mmcbootpart} 0x40007FC0 uImage\0" \
 	"mmcdev=0\0" \
include/configs/trats.h +3 -6
index a44792d85764..c3f891ae53d8 100644
@@ -40,9 +40,6 @@
 
 #define CONFIG_SYS_MONITOR_BASE	0x00000000
 
-#define CONFIG_BOOTBLOCK		"10"
-#define CONFIG_ENV_COMMON_BOOT		"${console} ${meminfo}"
-
 /* Tizen - partitions definitions */
 #define PARTS_CSA		"csa-mmc"
 #define PARTS_BOOT		"boot"
@@ -94,7 +91,7 @@
 		"setenv bootargs root=/dev/nfs rw " \
 		"nfsroot=${nfsroot},nolock,tcp " \
 		"ip=${ipaddr}:${serverip}:${gatewayip}:" \
-		"${netmask}:generic:usb0:off " CONFIG_ENV_COMMON_BOOT \
+		"${netmask}:generic:usb0:off ${console} ${meminfo}" \
 		"; run bootk\0" \
 	"ramfsboot=" \
 		"setenv bootargs root=/dev/ram0 rw rootfstype=ext2 " \
@@ -112,7 +109,7 @@
 	"console=console=ttySAC2,115200n8\0" \
 	"meminfo=crashkernel=32M@0x50000000\0" \
 	"nfsroot=/nfsroot/arm\0" \
-	"bootblock=" CONFIG_BOOTBLOCK "\0" \
+	"bootblock=10\0" \
 	"loaduimage=ext4load mmc ${mmcdev}:${mmcbootpart} 0x40007FC0 uImage\0" \
 	"loaddtb=ext4load mmc ${mmcdev}:${mmcbootpart} ${fdtaddr} " \
 		"${fdtfile}\0" \
@@ -141,7 +138,7 @@
 		   "setenv spl_imgsize;" \
 		   "setenv spl_imgaddr;" \
 		   "setenv spl_addr_tmp;\0" \
-	CONFIG_EXTRA_ENV_ITB \
+	ENV_ITB \
 	"fdtaddr=40800000\0" \
 
 /* Falcon mode definitions */
include/configs/trats2.h +1 -1
index 4b1eff08f3b3..e5f2b0cc993a 100644
@@ -125,7 +125,7 @@
 		   "setenv spl_imgsize;" \
 		   "setenv spl_imgaddr;" \
 		   "setenv spl_addr_tmp;\0" \
-	CONFIG_EXTRA_ENV_ITB \
+	ENV_ITB \
 	"fdtaddr=40800000\0" \
 
 /* GPT */
Reviewed-by on v1 1/3
#6 lore raw
In reply to Tom Rini

Hello Tom,

Quoted 8 lines · Tom Rini

Rename CONFIG_EXTRA_ENV_BOARD_SETTINGS to EXTRA_ENV_BOARD_SETTINGS in order to not further add to the CONFIG namespace.

Cc Heiko Schocher <[email protected]>
---
 include/configs/aristainetos2.h | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

Thanks!

bye,
Heiko

Signature · 3 lines
DENX Software Engineering GmbH,      Managing Director: Wolfgang Denk
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-52   Fax: +49-8142-66989-80   Email: [email protected]