dm: Kconfig: Move CONFIG_SYS_MALLOC_F_LEN to Kconfig
authorSimon Glass <sjg@chromium.org>
Wed, 11 Feb 2015 23:32:59 +0000 (16:32 -0700)
committerSimon Glass <sjg@chromium.org>
Thu, 12 Feb 2015 22:17:28 +0000 (15:17 -0700)
Move this option to Kconfig and update all boards.
Signed-off-by: Simon Glass <sjg@chromium.org>
47 files changed:
Kconfig
arch/arm/cpu/armv7/exynos/Kconfig
arch/arm/cpu/armv7/omap3/Kconfig
arch/arm/cpu/armv7/tegra-common/Kconfig
arch/arm/cpu/armv7/uniphier/Kconfig
arch/x86/Kconfig
board/ti/am335x/Kconfig
configs/Linksprite_pcDuino3_fdt_defconfig
configs/am335x_igep0033_defconfig
configs/cm_fx6_defconfig
configs/cm_t335_defconfig
configs/gwventana_defconfig
configs/mx6dlsabreauto_defconfig
configs/mx6qsabreauto_defconfig
configs/mx6qsabresd_defconfig
configs/mx6sxsabresd_defconfig
configs/nokia_rx51_defconfig
configs/pcm051_rev1_defconfig
configs/pcm051_rev3_defconfig
configs/pengwyn_defconfig
configs/pepper_defconfig
configs/rpi_defconfig
configs/s5p_goni_defconfig
configs/sandbox_defconfig
configs/smdkc100_defconfig
configs/snapper9260_defconfig
configs/snapper9g20_defconfig
configs/stv0991_defconfig
include/configs/cm_fx6.h
include/configs/exynos-common.h
include/configs/gw_ventana.h
include/configs/mx6sabre_common.h
include/configs/mx6sxsabresd.h
include/configs/nokia_rx51.h
include/configs/novena.h
include/configs/rpi.h
include/configs/s5p_goni.h
include/configs/sandbox.h
include/configs/smdkc100.h
include/configs/snapper9260.h
include/configs/stv0991.h
include/configs/sunxi-common.h
include/configs/tegra-common.h
include/configs/ti_am335x_common.h
include/configs/ti_omap3_common.h
include/configs/uniphier.h
include/configs/x86-common.h

diff --git a/Kconfig b/Kconfig
index 6112a77..75bab7f 100644 (file)
--- a/Kconfig
+++ b/Kconfig
@@ -56,6 +56,25 @@ config CC_OPTIMIZE_FOR_SIZE
 
          This option is enabled by default for U-Boot.
 
+config SYS_MALLOC_F
+       bool "Enable malloc() pool before relocation"
+       default 0x400
+       help
+         Before relocation memory is very limited on many platforms. Still,
+         we can provide a small malloc() pool if needed. Driver model in
+         particular needs this to operate, so that it can allocate the
+         initial serial device and any others that are needed.
+
+config SYS_MALLOC_F_LEN
+       hex "Size of malloc() pool before relocation"
+       depends on SYS_MALLOC_F
+       default 0x400
+       help
+         Before relocation memory is very limited on many platforms. Still,
+         we can provide a small malloc() pool if needed. Driver model in
+         particular needs this to operate, so that it can allocate the
+         initial serial device and any others that are needed.
+
 menuconfig EXPERT
         bool "Configure standard U-Boot features (expert users)"
         help
index 17ad567..2064efa 100644 (file)
@@ -80,6 +80,12 @@ config DM_SPI_FLASH
 config DM_GPIO
        default y if !SPL_BUILD
 
+config SYS_MALLOC_F
+       default y if !SPL_BUILD
+
+config SYS_MALLOC_F_LEN
+       default 0x400 if !SPL_BUILD
+
 source "board/samsung/smdkv310/Kconfig"
 source "board/samsung/trats/Kconfig"
 source "board/samsung/universal_c210/Kconfig"
index 2fe3232..4644098 100644 (file)
@@ -102,6 +102,12 @@ config DM_GPIO
 config DM_SERIAL
        default y if DM && !SPL_BUILD
 
+config SYS_MALLOC_F
+       default y if DM && !SPL_BUILD
+
+config SYS_MALLOC_F_LEN
+       default 0x400 if DM && !SPL_BUILD
+
 config SYS_SOC
        default "omap3"
 
index 93dc732..ee32469 100644 (file)
@@ -17,6 +17,12 @@ config TEGRA124
 
 endchoice
 
+config SYS_MALLOC_F
+       default y
+
+config SYS_MALLOC_F_LEN
+       default 0x1800
+
 config USE_PRIVATE_LIBGCC
        default y if SPL_BUILD
 
index 5c5a84f..1a47ac9 100644 (file)
@@ -48,6 +48,12 @@ config DCC_MICRO_SUPPORT_CARD
 
 endchoice
 
+config SYS_MALLOC_F
+       default y
+
+config SYS_MALLOC_F_LEN
+       default 0x2000
+
 config CMD_PINMON
        bool "Enable boot mode pins monitor command"
        default y
index bb3ff43..35d24e4 100644 (file)
@@ -76,6 +76,12 @@ config DM_GPIO
 config DM_SERIAL
        default y
 
+config SYS_MALLOC_F
+       default y
+
+config SYS_MALLOC_F_LEN
+       default 0x800
+
 config RAMBASE
        hex
        default 0x100000
index d6581ac..a20e0c1 100644 (file)
@@ -47,4 +47,10 @@ config DM_GPIO
 config DM_SERIAL
        default y if DM && !SPL_BUILD
 
+config SYS_MALLOC_F
+       default y if DM && !SPL_BUILD
+
+config SYS_MALLOC_F_LEN
+       default 0x400 if DM && !SPL_BUILD
+
 endif
index cfed375..1e749cd 100644 (file)
@@ -13,3 +13,5 @@ CONFIG_OF_SEPARATE=y
 +S:CONFIG_DRAM_CLK=480
 +S:CONFIG_DRAM_ZQ=122
 +S:CONFIG_DRAM_EMR1=4
+CONFIG_SYS_MALLOC_F=y
+CONFIG_SYS_MALLOC_F_LEN=0x400
index 23f0a32..f3544b5 100644 (file)
@@ -1,3 +1,5 @@
 CONFIG_SPL=y
 +S:CONFIG_ARM=y
 +S:CONFIG_TARGET_AM335X_IGEP0033=y
+CONFIG_SYS_MALLOC_F=y
+CONFIG_SYS_MALLOC_F_LEN=0x400
index d2ebf69..631698c 100644 (file)
@@ -5,3 +5,5 @@ CONFIG_SYS_EXTRA_OPTIONS="IMX_CONFIG=arch/arm/imx-common/spl_sd.cfg,MX6QDL,SPL"
 CONFIG_DM=y
 CONFIG_DM_GPIO=y
 CONFIG_DM_SERIAL=y
+CONFIG_SYS_MALLOC_F=y
+CONFIG_SYS_MALLOC_F_LEN=0x400
index 5ff4f9c..5c1d3cf 100644 (file)
@@ -1,3 +1,5 @@
 CONFIG_SPL=y
 +S:CONFIG_ARM=y
 +S:CONFIG_TARGET_CM_T335=y
+CONFIG_SYS_MALLOC_F=y
+CONFIG_SYS_MALLOC_F_LEN=0x400
index 4cddbdd..5b1a4c4 100644 (file)
@@ -2,3 +2,5 @@ CONFIG_SPL=y
 CONFIG_SYS_EXTRA_OPTIONS="IMX_CONFIG=arch/arm/imx-common/spl_sd.cfg,MX6QDL"
 +S:CONFIG_ARM=y
 +S:CONFIG_TARGET_GW_VENTANA=y
+CONFIG_SYS_MALLOC_F=y
+CONFIG_SYS_MALLOC_F_LEN=0x400
index b649935..ccdfe31 100644 (file)
@@ -1,3 +1,5 @@
 CONFIG_SYS_EXTRA_OPTIONS="IMX_CONFIG=board/freescale/mx6qsabreauto/mx6dl.cfg,MX6DL"
 CONFIG_ARM=y
 CONFIG_TARGET_MX6QSABREAUTO=y
+CONFIG_SYS_MALLOC_F=y
+CONFIG_SYS_MALLOC_F_LEN=0x400
index 7d86700..fe3d797 100644 (file)
@@ -1,3 +1,5 @@
 CONFIG_SYS_EXTRA_OPTIONS="IMX_CONFIG=board/freescale/mx6qsabreauto/imximage.cfg,MX6Q"
 CONFIG_ARM=y
 CONFIG_TARGET_MX6QSABREAUTO=y
+CONFIG_SYS_MALLOC_F=y
+CONFIG_SYS_MALLOC_F_LEN=0x400
index 67c1b77..09b0190 100644 (file)
@@ -1,3 +1,5 @@
 CONFIG_SYS_EXTRA_OPTIONS="IMX_CONFIG=board/freescale/mx6sabresd/mx6q_4x_mt41j128.cfg,MX6Q"
 CONFIG_ARM=y
 CONFIG_TARGET_MX6SABRESD=y
+CONFIG_SYS_MALLOC_F=y
+CONFIG_SYS_MALLOC_F_LEN=0x400
index f23d48f..72e0f10 100644 (file)
@@ -1,3 +1,5 @@
 CONFIG_SYS_EXTRA_OPTIONS="IMX_CONFIG=board/freescale/mx6sxsabresd/imximage.cfg,MX6SX"
 CONFIG_ARM=y
 CONFIG_TARGET_MX6SXSABRESD=y
+CONFIG_SYS_MALLOC_F=y
+CONFIG_SYS_MALLOC_F_LEN=0x400
index 20a51e1..1bb7664 100644 (file)
@@ -4,3 +4,5 @@ CONFIG_TARGET_NOKIA_RX51=y
 CONFIG_DM=n
 CONFIG_DM_SERIAL=n
 CONFIG_DM_GPIO=n
+CONFIG_SYS_MALLOC_F=y
+CONFIG_SYS_MALLOC_F_LEN=0x400
index 8b27682..baa2b23 100644 (file)
@@ -2,3 +2,5 @@ CONFIG_SPL=y
 CONFIG_SYS_EXTRA_OPTIONS="REV1"
 +S:CONFIG_ARM=y
 +S:CONFIG_TARGET_PCM051=y
+CONFIG_SYS_MALLOC_F=y
+CONFIG_SYS_MALLOC_F_LEN=0x400
index 27ad6ff..b5c62a6 100644 (file)
@@ -2,3 +2,5 @@ CONFIG_SPL=y
 CONFIG_SYS_EXTRA_OPTIONS="REV3"
 +S:CONFIG_ARM=y
 +S:CONFIG_TARGET_PCM051=y
+CONFIG_SYS_MALLOC_F=y
+CONFIG_SYS_MALLOC_F_LEN=0x400
index 1b9aa68..cbdd404 100644 (file)
@@ -1,3 +1,5 @@
 CONFIG_SPL=y
 +S:CONFIG_ARM=y
 +S:CONFIG_TARGET_PENGWYN=y
+CONFIG_SYS_MALLOC_F=y
+CONFIG_SYS_MALLOC_F_LEN=0x400
index 22c7bb4..14266ef 100644 (file)
@@ -1,3 +1,5 @@
 CONFIG_SPL=y
 +S:CONFIG_ARM=y
 +S:CONFIG_TARGET_PEPPER=y
+CONFIG_SYS_MALLOC_F=y
+CONFIG_SYS_MALLOC_F_LEN=0x400
index 9379cf0..98d3199 100644 (file)
@@ -1,2 +1,4 @@
 CONFIG_ARM=y
 CONFIG_TARGET_RPI=y
+CONFIG_SYS_MALLOC_F=y
+CONFIG_SYS_MALLOC_F_LEN=0x400
index 618e590..33e6fb8 100644 (file)
@@ -2,3 +2,5 @@ CONFIG_ARM=y
 CONFIG_ARCH_S5PC1XX=y
 CONFIG_TARGET_S5P_GONI=y
 CONFIG_DEFAULT_DEVICE_TREE="s5pc1xx-goni"
+CONFIG_SYS_MALLOC_F=y
+CONFIG_SYS_MALLOC_F_LEN=0x400
index 660063e..0bf5ea3 100644 (file)
@@ -5,3 +5,5 @@ CONFIG_FIT_VERBOSE=y
 CONFIG_FIT_SIGNATURE=y
 CONFIG_DM=y
 CONFIG_DEFAULT_DEVICE_TREE="sandbox"
+CONFIG_SYS_MALLOC_F=y
+CONFIG_SYS_MALLOC_F_LEN=0x400
index 041030f..e933a32 100644 (file)
@@ -2,3 +2,5 @@ CONFIG_ARM=y
 CONFIG_TARGET_SMDKC100=y
 CONFIG_ARCH_S5PC1XX=y
 CONFIG_DEFAULT_DEVICE_TREE="s5pc1xx-smdkc100"
+CONFIG_SYS_MALLOC_F=y
+CONFIG_SYS_MALLOC_F_LEN=0x400
index 035146c..97c49f3 100644 (file)
@@ -4,3 +4,5 @@ CONFIG_TARGET_SNAPPER9260=y
 CONFIG_DM=y
 CONFIG_DM_GPIO=y
 CONFIG_DM_SERIAL=y
+CONFIG_SYS_MALLOC_F=y
+CONFIG_SYS_MALLOC_F_LEN=0x400
index 66c44cc..d5f1d9f 100644 (file)
@@ -4,3 +4,5 @@ CONFIG_TARGET_SNAPPER9260=y
 CONFIG_DM=y
 CONFIG_DM_GPIO=y
 CONFIG_DM_SERIAL=y
+CONFIG_SYS_MALLOC_F=y
+CONFIG_SYS_MALLOC_F_LEN=0x400
index a05e991..37b10ba 100644 (file)
@@ -1,3 +1,5 @@
 CONFIG_SYS_EXTRA_OPTIONS="stv0991"
 CONFIG_ARM=y
 CONFIG_TARGET_STV0991=y
+CONFIG_SYS_MALLOC_F=y
+CONFIG_SYS_MALLOC_F_LEN=0x2000
index 4008306..4207504 100644 (file)
 #define CONFIG_MACH_TYPE               4273
 
 #ifndef CONFIG_SPL_BUILD
-
 #define CONFIG_CMD_GPIO
-
-#define CONFIG_SYS_MALLOC_F_LEN                (1 << 10)
 #endif
 
 /* Display information on boot */
index 2c4f35a..59676ae 100644 (file)
@@ -36,7 +36,6 @@
 #define CONFIG_ENV_OVERWRITE
 
 /* Size of malloc() pool before and after relocation */
-#define CONFIG_SYS_MALLOC_F_LEN                (1 << 10)
 #define CONFIG_SYS_MALLOC_LEN          (CONFIG_ENV_SIZE + (80 << 20))
 
 /* select serial console configuration */
index 4f137fc..620f950 100644 (file)
@@ -39,7 +39,6 @@
 
 /* Size of malloc() pool */
 #define CONFIG_SYS_MALLOC_LEN          (10 * 1024 * 1024)
-#define CONFIG_SYS_MALLOC_F_LEN                (1 << 10)
 
 /* Init Functions */
 #define CONFIG_BOARD_EARLY_INIT_F
index f0f721e..80e48d1 100644 (file)
@@ -27,7 +27,6 @@
 
 #define CONFIG_DM
 #define CONFIG_DM_THERMAL
-#define CONFIG_SYS_MALLOC_F_LEN        (1 << 10)
 #define CONFIG_IMX6_THERMAL
 
 #define CONFIG_SYS_GENERIC_BOARD
index 404b922..1005b9e 100644 (file)
 
 #define CONFIG_DM
 #define CONFIG_DM_THERMAL
-#define CONFIG_SYS_MALLOC_F_LEN        (1 << 10)
 #define CONFIG_IMX6_THERMAL
 
 #define CONFIG_CMD_FUSE
index 6e1f501..46fc91e 100644 (file)
@@ -72,7 +72,6 @@
 #define CONFIG_UBI_SIZE                        (512 << 10)
 #define CONFIG_SYS_MALLOC_LEN          (CONFIG_ENV_SIZE + CONFIG_UBI_SIZE + \
                                        (128 << 10))
-#define CONFIG_SYS_MALLOC_F_LEN                (1 << 10)
 
 /*
  * Hardware drivers
index ea75d2c..074110c 100644 (file)
 #define CONFIG_SYS_MEMTEST_END         0x20000000
 
 #define CONFIG_SYS_MALLOC_LEN          (64 * 1024 * 1024)
-#define CONFIG_SYS_MALLOC_F_LEN                (1 << 10)
 
 /* SPL */
 #define CONFIG_SPL_FAT_SUPPORT
index ea19ad8..7ad8d08 100644 (file)
@@ -46,7 +46,6 @@
                                         CONFIG_SYS_SDRAM_SIZE - \
                                         GENERATED_GBL_DATA_SIZE)
 #define CONFIG_SYS_MALLOC_LEN          SZ_4M
-#define CONFIG_SYS_MALLOC_F_LEN                (1 << 10)
 #define CONFIG_SYS_MEMTEST_START       0x00100000
 #define CONFIG_SYS_MEMTEST_END         0x00200000
 #define CONFIG_LOADADDR                        0x00200000
index 26167a4..8fadc68 100644 (file)
@@ -40,7 +40,6 @@
 #define CONFIG_CMDLINE_EDITING
 
 /* Size of malloc() pool before and after relocation */
-#define CONFIG_SYS_MALLOC_F_LEN                (1 << 10)
 #define CONFIG_SYS_MALLOC_LEN          (CONFIG_ENV_SIZE + (80 << 20))
 
 /*
index bff0170..5c11650 100644 (file)
@@ -60,7 +60,6 @@
 /*
  * Size of malloc() pool, before and after relocation
  */
-#define CONFIG_SYS_MALLOC_F_LEN        (1 << 10)
 #define CONFIG_MALLOC_F_ADDR           0x0010000
 #define CONFIG_SYS_MALLOC_LEN          (32 << 20)      /* 32MB  */
 
index a7eb33e..080fc3a 100644 (file)
@@ -48,9 +48,6 @@
  */
 #define CONFIG_SYS_MALLOC_LEN          (CONFIG_ENV_SIZE + (1 << 20))
 
-/* Small malloc pool before relocation */
-#define CONFIG_SYS_MALLOC_F_LEN                (1 << 10)
-
 /*
  * select serial console configuration
  */
index 712f9b7..6c68596 100644 (file)
@@ -21,7 +21,6 @@
 #define CONFIG_SYS_AT91_MAIN_CLOCK     18432000 /* External Crystal, in Hz */
 #define CONFIG_SYS_AT91_SLOW_CLOCK     32768
 #define CONFIG_SYS_GENERIC_BOARD
-#define CONFIG_SYS_MALLOC_F_LEN                (1 << 10)
 
 /* CPU */
 #define CONFIG_ARCH_CPU_INIT
index fd9bd63..071b1c2 100644 (file)
@@ -28,7 +28,6 @@
        (PHYS_SDRAM_1_SIZE - CONFIG_ENV_SIZE)
 #define CONFIG_SYS_MAXARGS                     16
 #define CONFIG_SYS_MALLOC_LEN                  (CONFIG_ENV_SIZE + 16 * 1024)
-#define CONFIG_SYS_MALLOC_F_LEN                        0x2000
 
 #define CONFIG_DM
 /* serial port (PL011) configuration */
index 0c5c18c..09889ee 100644 (file)
@@ -29,7 +29,6 @@
 
 #if !defined(CONFIG_SPL_BUILD) && defined(CONFIG_DM)
 # define CONFIG_DW_SERIAL
-# define CONFIG_SYS_MALLOC_F_LEN       (1 << 10)
 #endif
 
 /*
index ef25980..005fc6a 100644 (file)
@@ -37,7 +37,6 @@
  * Size of malloc() pool
  */
 #define CONFIG_SYS_MALLOC_LEN          (4 << 20)       /* 4MB  */
-#define CONFIG_SYS_MALLOC_F_LEN                (1 << 10)
 
 #define CONFIG_SYS_NONCACHED_MEMORY    (1 << 20)       /* 1 MiB */
 
index 4ce9d49..20a55f4 100644 (file)
@@ -21,7 +21,6 @@
 
 #ifndef CONFIG_SPL_BUILD
 # define CONFIG_OMAP_SERIAL
-# define CONFIG_SYS_MALLOC_F_LEN       (1 << 10)
 #endif
 
 #include <asm/arch/omap.h>
index 77211de..840e108 100644 (file)
@@ -20,7 +20,6 @@
 
 #ifndef CONFIG_SPL_BUILD
 # define CONFIG_OMAP_SERIAL
-# define CONFIG_SYS_MALLOC_F_LEN       (1 << 10)
 #endif
 
 /* The chip has SDRC controller */
index 6f4ecc9..3f738fb 100644 (file)
@@ -80,8 +80,6 @@
 #define CONFIG_SMC911X_BASE            CONFIG_SUPPORT_CARD_ETHER_BASE
 #define CONFIG_SMC911X_32_BIT
 
-#define CONFIG_SYS_MALLOC_F_LEN  0x2000
-
 /*-----------------------------------------------------------------------
  * MMU and Cache Setting
  *----------------------------------------------------------------------*/
index 277a95c..994874c 100644 (file)
 #define CONFIG_SYS_STACK_SIZE                  (32 * 1024)
 #define CONFIG_SYS_MONITOR_BASE                CONFIG_SYS_TEXT_BASE
 #define CONFIG_SYS_MALLOC_LEN                  0x200000
-#define CONFIG_SYS_MALLOC_F_LEN                        (2 << 10)
 
 /* allow to overwrite serial and ethaddr */
 #define CONFIG_ENV_OVERWRITE