[PATCH 084/149] global: Migrate CONFIG_MALLOC_F_ADDR to CFG

Tom Rini trini at konsulko.com
Sun Dec 4 16:04:49 CET 2022


Perform a simple rename of CONFIG_MALLOC_F_ADDR to CFG_MALLOC_F_ADDR

Signed-off-by: Tom Rini <trini at konsulko.com>
---
 arch/sandbox/cpu/start.c                    | 2 +-
 common/init/board_init.c                    | 2 +-
 common/spl/spl.c                            | 4 ++--
 doc/arch/sandbox/sandbox.rst                | 2 +-
 include/configs/capricorn-common.h          | 2 +-
 include/configs/cgtqmx8.h                   | 2 +-
 include/configs/imx8mm-cl-iot-gate.h        | 2 +-
 include/configs/imx8mm_beacon.h             | 2 +-
 include/configs/imx8mm_data_modul_edm_sbc.h | 2 +-
 include/configs/imx8mm_evk.h                | 2 +-
 include/configs/imx8mm_icore_mx8mm.h        | 2 +-
 include/configs/imx8mm_venice.h             | 2 +-
 include/configs/imx8mp_rsb3720.h            | 2 +-
 include/configs/imx8mq_cm.h                 | 2 +-
 include/configs/imx8mq_evk.h                | 2 +-
 include/configs/imx8mq_phanbell.h           | 2 +-
 include/configs/imx8qm_mek.h                | 2 +-
 include/configs/imx8qxp_mek.h               | 2 +-
 include/configs/imx8ulp_evk.h               | 2 +-
 include/configs/imx93_evk.h                 | 2 +-
 include/configs/kontron-sl-mx8mm.h          | 2 +-
 include/configs/kontron_pitx_imx8m.h        | 2 +-
 include/configs/kontron_sl28.h              | 2 +-
 include/configs/phycore_imx8mm.h            | 2 +-
 include/configs/pico-imx8mq.h               | 2 +-
 include/configs/sandbox.h                   | 2 +-
 include/configs/verdin-imx8mm.h             | 2 +-
 include/configs/verdin-imx8mp.h             | 2 +-
 28 files changed, 29 insertions(+), 29 deletions(-)

diff --git a/arch/sandbox/cpu/start.c b/arch/sandbox/cpu/start.c
index 622df41f54cf..234652872ecc 100644
--- a/arch/sandbox/cpu/start.c
+++ b/arch/sandbox/cpu/start.c
@@ -535,7 +535,7 @@ int sandbox_main(int argc, char *argv[])
 	}
 
 #if CONFIG_VAL(SYS_MALLOC_F_LEN)
-	gd->malloc_base = CONFIG_MALLOC_F_ADDR;
+	gd->malloc_base = CFG_MALLOC_F_ADDR;
 #endif
 #if CONFIG_IS_ENABLED(LOG)
 	gd->default_log_level = state->default_log_level;
diff --git a/common/init/board_init.c b/common/init/board_init.c
index 6a550261778d..96ffb79a9869 100644
--- a/common/init/board_init.c
+++ b/common/init/board_init.c
@@ -78,7 +78,7 @@ __weak void board_init_f_init_stack_protection(void)
 ulong board_init_f_alloc_reserve(ulong top)
 {
 	/* Reserve early malloc arena */
-#ifndef CONFIG_MALLOC_F_ADDR
+#ifndef CFG_MALLOC_F_ADDR
 #if CONFIG_VAL(SYS_MALLOC_F_LEN)
 	top -= CONFIG_VAL(SYS_MALLOC_F_LEN);
 #endif
diff --git a/common/spl/spl.c b/common/spl/spl.c
index 1d2e8fda7284..4668367b680f 100644
--- a/common/spl/spl.c
+++ b/common/spl/spl.c
@@ -527,8 +527,8 @@ static int spl_common_init(bool setup_malloc)
 
 #if CONFIG_VAL(SYS_MALLOC_F_LEN)
 	if (setup_malloc) {
-#ifdef CONFIG_MALLOC_F_ADDR
-		gd->malloc_base = CONFIG_MALLOC_F_ADDR;
+#ifdef CFG_MALLOC_F_ADDR
+		gd->malloc_base = CFG_MALLOC_F_ADDR;
 #endif
 		gd->malloc_limit = CONFIG_VAL(SYS_MALLOC_F_LEN);
 		gd->malloc_ptr = 0;
diff --git a/doc/arch/sandbox/sandbox.rst b/doc/arch/sandbox/sandbox.rst
index e6d840365166..cd7f8a2cb0dc 100644
--- a/doc/arch/sandbox/sandbox.rst
+++ b/doc/arch/sandbox/sandbox.rst
@@ -615,7 +615,7 @@ Addr      Config                     Usage
 =======   ========================   ===============================
       0   CONFIG_SYS_FDT_LOAD_ADDR   Device tree
    c000   CONFIG_BLOBLIST_ADDR       Blob list
-  10000   CONFIG_MALLOC_F_ADDR       Early memory allocation
+  10000   CFG_MALLOC_F_ADDR          Early memory allocation
   f0000   CONFIG_PRE_CON_BUF_ADDR    Pre-console buffer
  100000   CONFIG_TRACE_EARLY_ADDR    Early trace buffer (if enabled). Also used
                                      as the SPL load buffer in spl_test_load().
diff --git a/include/configs/capricorn-common.h b/include/configs/capricorn-common.h
index 19c7fca03b29..9e7322cdb937 100644
--- a/include/configs/capricorn-common.h
+++ b/include/configs/capricorn-common.h
@@ -14,7 +14,7 @@
 
 /* SPL config */
 #ifdef CONFIG_SPL_BUILD
-#define CONFIG_MALLOC_F_ADDR		0x00120000
+#define CFG_MALLOC_F_ADDR		0x00120000
 
 #endif /* CONFIG_SPL_BUILD */
 
diff --git a/include/configs/cgtqmx8.h b/include/configs/cgtqmx8.h
index caa1498acead..a63325973846 100644
--- a/include/configs/cgtqmx8.h
+++ b/include/configs/cgtqmx8.h
@@ -13,7 +13,7 @@
 
 #ifdef CONFIG_SPL_BUILD
 #define CONFIG_SERIAL_LPUART_BASE	0x5a060000
-#define CONFIG_MALLOC_F_ADDR		0x00120000
+#define CFG_MALLOC_F_ADDR		0x00120000
 
 #endif
 
diff --git a/include/configs/imx8mm-cl-iot-gate.h b/include/configs/imx8mm-cl-iot-gate.h
index 7785bdc7cbe6..64cdc401d039 100644
--- a/include/configs/imx8mm-cl-iot-gate.h
+++ b/include/configs/imx8mm-cl-iot-gate.h
@@ -16,7 +16,7 @@
 
 #ifdef CONFIG_SPL_BUILD
 /* malloc f used before GD_FLG_FULL_MALLOC_INIT set */
-#define CONFIG_MALLOC_F_ADDR		0x912000
+#define CFG_MALLOC_F_ADDR		0x912000
 /* For RAW image gives a error info not panic */
 
 #endif
diff --git a/include/configs/imx8mm_beacon.h b/include/configs/imx8mm_beacon.h
index ee524f0e63f2..d85ae21e2317 100644
--- a/include/configs/imx8mm_beacon.h
+++ b/include/configs/imx8mm_beacon.h
@@ -14,7 +14,7 @@
 
 #ifdef CONFIG_SPL_BUILD
 /* malloc f used before GD_FLG_FULL_MALLOC_INIT set */
-#define CONFIG_MALLOC_F_ADDR		0x930000
+#define CFG_MALLOC_F_ADDR		0x930000
 /* For RAW image gives a error info not panic */
 
 #endif
diff --git a/include/configs/imx8mm_data_modul_edm_sbc.h b/include/configs/imx8mm_data_modul_edm_sbc.h
index 44d74bb1a788..0723d27ab703 100644
--- a/include/configs/imx8mm_data_modul_edm_sbc.h
+++ b/include/configs/imx8mm_data_modul_edm_sbc.h
@@ -11,7 +11,7 @@
 #include <asm/arch/imx-regs.h>
 
 #ifdef CONFIG_SPL_BUILD
-#define CONFIG_MALLOC_F_ADDR		0x930000
+#define CFG_MALLOC_F_ADDR		0x930000
 
 /* For RAW image gives a error info not panic */
 
diff --git a/include/configs/imx8mm_evk.h b/include/configs/imx8mm_evk.h
index c364e06dc450..d5642b96495f 100644
--- a/include/configs/imx8mm_evk.h
+++ b/include/configs/imx8mm_evk.h
@@ -24,7 +24,7 @@
 
 #ifdef CONFIG_SPL_BUILD
 /* malloc f used before GD_FLG_FULL_MALLOC_INIT set */
-#define CONFIG_MALLOC_F_ADDR		0x930000
+#define CFG_MALLOC_F_ADDR		0x930000
 /* For RAW image gives a error info not panic */
 
 #endif
diff --git a/include/configs/imx8mm_icore_mx8mm.h b/include/configs/imx8mm_icore_mx8mm.h
index e718daa07c3e..2158b0af74f9 100644
--- a/include/configs/imx8mm_icore_mx8mm.h
+++ b/include/configs/imx8mm_icore_mx8mm.h
@@ -15,7 +15,7 @@
 
 #ifdef CONFIG_SPL_BUILD
 /* malloc f used before GD_FLG_FULL_MALLOC_INIT set */
-# define CONFIG_MALLOC_F_ADDR		0x930000
+# define CFG_MALLOC_F_ADDR		0x930000
 /* For RAW image gives a error info not panic */
 #endif /* CONFIG_SPL_BUILD */
 
diff --git a/include/configs/imx8mm_venice.h b/include/configs/imx8mm_venice.h
index c490e3829f9a..5579a05d165f 100644
--- a/include/configs/imx8mm_venice.h
+++ b/include/configs/imx8mm_venice.h
@@ -14,7 +14,7 @@
 
 #ifdef CONFIG_SPL_BUILD
 /* malloc f used before GD_FLG_FULL_MALLOC_INIT set */
-#define CONFIG_MALLOC_F_ADDR		0x930000
+#define CFG_MALLOC_F_ADDR		0x930000
 #endif
 
 /* Enable Distro Boot */
diff --git a/include/configs/imx8mp_rsb3720.h b/include/configs/imx8mp_rsb3720.h
index 38ae5f137022..e4e24b522fdb 100644
--- a/include/configs/imx8mp_rsb3720.h
+++ b/include/configs/imx8mp_rsb3720.h
@@ -24,7 +24,7 @@
 		 0x5f, 0xd3, 0x6b, 0x9b, 0xe5, 0xb9)
 
 #ifdef CONFIG_SPL_BUILD
-#define CONFIG_MALLOC_F_ADDR		0x184000 /* malloc f used before \
+#define CFG_MALLOC_F_ADDR		0x184000 /* malloc f used before \
 						  * GD_FLG_FULL_MALLOC_INIT \
 						  * set \
 						  */
diff --git a/include/configs/imx8mq_cm.h b/include/configs/imx8mq_cm.h
index f6f356d27ba2..f7ae1b47d063 100644
--- a/include/configs/imx8mq_cm.h
+++ b/include/configs/imx8mq_cm.h
@@ -14,7 +14,7 @@
 #define CONFIG_SYS_SPL_PTE_RAM_BASE    0x41580000
 
 /* malloc f used before GD_FLG_FULL_MALLOC_INIT set */
-#define CONFIG_MALLOC_F_ADDR		0x182000
+#define CFG_MALLOC_F_ADDR		0x182000
 /* For RAW image gives a error info not panic */
 
 #endif
diff --git a/include/configs/imx8mq_evk.h b/include/configs/imx8mq_evk.h
index d9ce5d5d0f1a..4b46321e8512 100644
--- a/include/configs/imx8mq_evk.h
+++ b/include/configs/imx8mq_evk.h
@@ -15,7 +15,7 @@
 #define CONFIG_SYS_SPL_PTE_RAM_BASE    0x41580000
 
 /* malloc f used before GD_FLG_FULL_MALLOC_INIT set */
-#define CONFIG_MALLOC_F_ADDR		0x182000
+#define CFG_MALLOC_F_ADDR		0x182000
 /* For RAW image gives a error info not panic */
 
 #define CONFIG_POWER_PFUZE100_I2C_ADDR 0x08
diff --git a/include/configs/imx8mq_phanbell.h b/include/configs/imx8mq_phanbell.h
index eb7059f0648c..5158f2cc605a 100644
--- a/include/configs/imx8mq_phanbell.h
+++ b/include/configs/imx8mq_phanbell.h
@@ -14,7 +14,7 @@
 #define CONFIG_SYS_SPL_PTE_RAM_BASE    0x41580000
 
 /* malloc f used before GD_FLG_FULL_MALLOC_INIT set */
-#define CONFIG_MALLOC_F_ADDR		0x182000
+#define CFG_MALLOC_F_ADDR		0x182000
 /* For RAW image gives a error info not panic */
 #endif
 
diff --git a/include/configs/imx8qm_mek.h b/include/configs/imx8qm_mek.h
index 7772e71013ef..a25efbb16bdb 100644
--- a/include/configs/imx8qm_mek.h
+++ b/include/configs/imx8qm_mek.h
@@ -12,7 +12,7 @@
 
 #ifdef CONFIG_SPL_BUILD
 #define CONFIG_SERIAL_LPUART_BASE	0x5a060000
-#define CONFIG_MALLOC_F_ADDR		0x00120000
+#define CFG_MALLOC_F_ADDR		0x00120000
 
 #endif
 
diff --git a/include/configs/imx8qxp_mek.h b/include/configs/imx8qxp_mek.h
index 669da591fa2b..4f55ae49403d 100644
--- a/include/configs/imx8qxp_mek.h
+++ b/include/configs/imx8qxp_mek.h
@@ -12,7 +12,7 @@
 
 #ifdef CONFIG_SPL_BUILD
 #define CONFIG_SERIAL_LPUART_BASE	0x5a060000
-#define CONFIG_MALLOC_F_ADDR		0x00120000
+#define CFG_MALLOC_F_ADDR		0x00120000
 
 #endif
 
diff --git a/include/configs/imx8ulp_evk.h b/include/configs/imx8ulp_evk.h
index b7397f6038fd..d77510e1685e 100644
--- a/include/configs/imx8ulp_evk.h
+++ b/include/configs/imx8ulp_evk.h
@@ -12,7 +12,7 @@
 #define CFG_SYS_UBOOT_BASE	(QSPI0_AMBA_BASE + CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR * 512)
 
 #ifdef CONFIG_SPL_BUILD
-#define CONFIG_MALLOC_F_ADDR		0x22040000
+#define CFG_MALLOC_F_ADDR		0x22040000
 
 
 #endif
diff --git a/include/configs/imx93_evk.h b/include/configs/imx93_evk.h
index 5cd6492dd503..7b7bef3ca755 100644
--- a/include/configs/imx93_evk.h
+++ b/include/configs/imx93_evk.h
@@ -14,7 +14,7 @@
 	(QSPI0_AMBA_BASE + CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR * 512)
 
 #ifdef CONFIG_SPL_BUILD
-#define CONFIG_MALLOC_F_ADDR		0x204D0000
+#define CFG_MALLOC_F_ADDR		0x204D0000
 #endif
 
 #ifdef CONFIG_DISTRO_DEFAULTS
diff --git a/include/configs/kontron-sl-mx8mm.h b/include/configs/kontron-sl-mx8mm.h
index e4d6a8a15408..d80238bd02f2 100644
--- a/include/configs/kontron-sl-mx8mm.h
+++ b/include/configs/kontron-sl-mx8mm.h
@@ -46,7 +46,7 @@
 
 #ifdef CONFIG_SPL_BUILD
 /* malloc f used before GD_FLG_FULL_MALLOC_INIT set */
-#define CONFIG_MALLOC_F_ADDR		0x930000
+#define CFG_MALLOC_F_ADDR		0x930000
 #endif
 
 #define CFG_EXTRA_ENV_SETTINGS BOOTENV
diff --git a/include/configs/kontron_pitx_imx8m.h b/include/configs/kontron_pitx_imx8m.h
index 4dd51c7f1d7f..5a3c9f76a431 100644
--- a/include/configs/kontron_pitx_imx8m.h
+++ b/include/configs/kontron_pitx_imx8m.h
@@ -16,7 +16,7 @@
 #define CONFIG_SYS_SPL_PTE_RAM_BASE     0x41580000
 
 /* malloc f used before GD_FLG_FULL_MALLOC_INIT set */
-#define CONFIG_MALLOC_F_ADDR		0x182000
+#define CFG_MALLOC_F_ADDR		0x182000
 /* For RAW image gives a error info not panic */
 
 
diff --git a/include/configs/kontron_sl28.h b/include/configs/kontron_sl28.h
index 0d293f316b7f..940bfd2b336a 100644
--- a/include/configs/kontron_sl28.h
+++ b/include/configs/kontron_sl28.h
@@ -28,7 +28,7 @@
 /* generic timer */
 
 /* early heap for SPL DM */
-#define CONFIG_MALLOC_F_ADDR		CFG_SYS_FSL_OCRAM_BASE
+#define CFG_MALLOC_F_ADDR		CFG_SYS_FSL_OCRAM_BASE
 
 /* serial port */
 #define CFG_SYS_NS16550_CLK          (get_bus_freq(0) / 2)
diff --git a/include/configs/phycore_imx8mm.h b/include/configs/phycore_imx8mm.h
index 9160c78c0464..ce6dc87c69c7 100644
--- a/include/configs/phycore_imx8mm.h
+++ b/include/configs/phycore_imx8mm.h
@@ -16,7 +16,7 @@
 
 #ifdef CONFIG_SPL_BUILD
 /* malloc f used before GD_FLG_FULL_MALLOC_INIT set */
-#define CONFIG_MALLOC_F_ADDR		0x930000
+#define CFG_MALLOC_F_ADDR		0x930000
 /* For RAW image gives a error info not panic */
 #endif
 
diff --git a/include/configs/pico-imx8mq.h b/include/configs/pico-imx8mq.h
index 1d8709180c83..37ade717ae99 100644
--- a/include/configs/pico-imx8mq.h
+++ b/include/configs/pico-imx8mq.h
@@ -14,7 +14,7 @@
 #define CONFIG_SYS_SPL_PTE_RAM_BASE	0x41580000
 
 /* malloc f used before GD_FLG_FULL_MALLOC_INIT set */
-#define CONFIG_MALLOC_F_ADDR		0x182000
+#define CFG_MALLOC_F_ADDR		0x182000
 /* For RAW image gives a error info not panic */
 #endif
 
diff --git a/include/configs/sandbox.h b/include/configs/sandbox.h
index 8d9af7f088d1..4e5653dc886e 100644
--- a/include/configs/sandbox.h
+++ b/include/configs/sandbox.h
@@ -6,7 +6,7 @@
 #ifndef __CONFIG_H
 #define __CONFIG_H
 
-#define CONFIG_MALLOC_F_ADDR		0x0010000
+#define CFG_MALLOC_F_ADDR		0x0010000
 
 /* Size of our emulated memory */
 #define SB_CONCAT(x, y) x ## y
diff --git a/include/configs/verdin-imx8mm.h b/include/configs/verdin-imx8mm.h
index 7f3fa795afdc..27d7efb883de 100644
--- a/include/configs/verdin-imx8mm.h
+++ b/include/configs/verdin-imx8mm.h
@@ -14,7 +14,7 @@
 
 #ifdef CONFIG_SPL_BUILD
 /* malloc f used before GD_FLG_FULL_MALLOC_INIT set */
-#define CONFIG_MALLOC_F_ADDR		0x930000
+#define CFG_MALLOC_F_ADDR		0x930000
 /* For RAW image gives a error info not panic */
 #endif
 
diff --git a/include/configs/verdin-imx8mp.h b/include/configs/verdin-imx8mp.h
index 2cb076cabac9..942081ab84d7 100644
--- a/include/configs/verdin-imx8mp.h
+++ b/include/configs/verdin-imx8mp.h
@@ -16,7 +16,7 @@
 /*#define CONFIG_ENABLE_DDR_TRAINING_DEBUG*/
 
 /* malloc f used before GD_FLG_FULL_MALLOC_INIT set */
-#define CONFIG_MALLOC_F_ADDR				0x184000
+#define CFG_MALLOC_F_ADDR				0x184000
 /* For RAW image gives a error info not panic */
 
 #endif /* CONFIG_SPL_BUILD */
-- 
2.25.1



More information about the U-Boot mailing list