ti_armv7_common: env: Consolidate MMC args
authorLokesh Vutla <lokeshvutla@ti.com>
Fri, 28 Aug 2015 08:05:07 +0000 (13:35 +0530)
committerTom Rini <trini@konsulko.com>
Fri, 11 Sep 2015 18:05:37 +0000 (14:05 -0400)
Define default mmc args in ti_armv7_common.h so that all
TI platforms can reuse.

Reported-by: Yan Liu <yan-liu@ti.com>
Signed-off-by: Lokesh Vutla <lokeshvutla@ti.com>
include/configs/am335x_evm.h
include/configs/am43xx_evm.h
include/configs/ti_armv7_common.h
include/configs/ti_omap4_common.h
include/configs/ti_omap5_common.h

index e89c49e1e3a0a0f7c4c2b6c0f7080c2330af562d..3cf768e662d634a6d3dd09209ee1c28bc545687d 100644 (file)
@@ -70,6 +70,7 @@
 #ifndef CONFIG_SPL_BUILD
 #define CONFIG_EXTRA_ENV_SETTINGS \
        DEFAULT_LINUX_BOOT_ENV \
+       DEFAULT_MMC_TI_ARGS \
        "boot_fdt=try\0" \
        "bootpart=0:2\0" \
        "bootdir=/boot\0" \
                "uuid_disk=${uuid_gpt_disk};" \
                "name=rootfs,start=2MiB,size=-,uuid=${uuid_gpt_rootfs}\0" \
        "optargs=\0" \
-       "mmcdev=0\0" \
-       "mmcroot=/dev/mmcblk0p2 ro\0" \
-       "mmcrootfstype=ext4 rootwait\0" \
        "ramroot=/dev/ram0 rw\0" \
        "ramrootfstype=ext2\0" \
-       "mmcargs=setenv bootargs console=${console} " \
-               "${optargs} " \
-               "root=${mmcroot} " \
-               "rootfstype=${mmcrootfstype}\0" \
        "spiroot=/dev/mtdblock4 rw\0" \
        "spirootfstype=jffs2\0" \
        "spisrcaddr=0xe0000\0" \
        "loadramdisk=load mmc ${mmcdev} ${rdaddr} ramdisk.gz\0" \
        "loadimage=load mmc ${bootpart} ${loadaddr} ${bootdir}/${bootfile}\0" \
        "loadfdt=load mmc ${bootpart} ${fdtaddr} ${bootdir}/${fdtfile}\0" \
-       "mmcloados=run mmcargs; " \
+       "mmcloados=run args_mmc; " \
                "if test ${boot_fdt} = yes || test ${boot_fdt} = try; then " \
                        "if run loadfdt; then " \
                                "bootz ${loadaddr} - ${fdtaddr}; " \
index 15fa3e3fecea49903413194991722c139fbdf608..d868442acb5ae9d8ff3aa31a1f26b7a5a51b349b 100644 (file)
 #ifndef CONFIG_SPL_BUILD
 #define CONFIG_EXTRA_ENV_SETTINGS \
        DEFAULT_LINUX_BOOT_ENV \
+       DEFAULT_MMC_TI_ARGS \
        "fdtfile=undefined\0" \
        "bootpart=0:2\0" \
        "bootdir=/boot\0" \
                "uuid_disk=${uuid_gpt_disk};" \
                "name=rootfs,start=2MiB,size=-,uuid=${uuid_gpt_rootfs}\0" \
        "optargs=\0" \
-       "mmcdev=0\0" \
-       "mmcroot=/dev/mmcblk0p2 rw\0" \
-       "mmcrootfstype=ext4 rootwait\0" \
        "usbroot=/dev/sda2 rw\0" \
        "usbrootfstype=ext4 rootwait\0" \
        "usbdev=0\0" \
        "ramroot=/dev/ram0 rw\0" \
        "ramrootfstype=ext2\0" \
-       "mmcargs=setenv bootargs console=${console} " \
-               "${optargs} " \
-               "root=${mmcroot} " \
-               "rootfstype=${mmcrootfstype}\0" \
        "usbargs=setenv bootargs console=${console} " \
                "${optargs} " \
                "root=${usbroot} " \
                        "if run loadimage; then " \
                                "run loadfdt; " \
                                "echo Booting from mmc${mmcdev} ...; " \
-                               "run mmcargs; " \
+                               "run args_mmc; " \
                                "bootz ${loadaddr} - ${fdtaddr}; " \
                        "fi;" \
                "fi;\0" \
index 18fca02c4c383ccdd9bfb4033aaebf12de7a8e8a..1a4b6d9900a2d84a05fbda72cee510581a183f9f 100644 (file)
        "ramdisk_addr_r=0x88080000\0" \
        "bootm_size=0x10000000\0"
 
+#define DEFAULT_MMC_TI_ARGS \
+       "mmcdev=0\0" \
+       "mmcrootfstype=ext4 rootwait\0" \
+       "args_mmc=setenv bootargs console=${console} " \
+               "${optargs} " \
+               "root=${mmcroot} " \
+               "rootfstype=${mmcrootfstype}\0"
+
 /*
  * Default to a quick boot delay.
  */
index 6139246daa20dec9bb227564e11d7ecb2916d421..1cd7dae85b3fe563656a7ef9b38352d146eb6d0e 100644 (file)
@@ -83,6 +83,7 @@
  */
 #define CONFIG_EXTRA_ENV_SETTINGS \
        DEFAULT_LINUX_BOOT_ENV \
+       DEFAULT_MMC_TI_ARGS \
        "console=ttyO2,115200n8\0" \
        "fdtfile=undefined\0" \
        "bootpart=0:2\0" \
        "bootfile=zImage\0" \
        "usbtty=cdc_acm\0" \
        "vram=16M\0" \
-       "mmcdev=0\0" \
-       "mmcroot=/dev/mmcblk0p2 rw\0" \
-       "mmcrootfstype=ext4 rootwait\0" \
-       "mmcargs=setenv bootargs console=${console} " \
-               "vram=${vram} " \
-               "root=${mmcroot} " \
-               "rootfstype=${mmcrootfstype}\0" \
        "loadbootscript=load mmc ${mmcdev} ${loadaddr} boot.scr\0" \
        "bootscript=echo Running bootscript from mmc${mmcdev} ...; " \
                "source ${loadaddr}\0" \
        "loadimage=load mmc ${bootpart} ${loadaddr} ${bootdir}/${bootfile}\0" \
        "loaduimage=load mmc ${mmcdev} ${loadaddr} uImage\0" \
        "mmcboot=echo Booting from mmc${mmcdev} ...; " \
-               "run mmcargs; " \
+               "run args_mmc; " \
                "bootz ${loadaddr} - ${fdtaddr}\0" \
        "uimageboot=echo Booting from mmc${mmcdev} ...; " \
-               "run mmcargs; " \
+               "run args_mmc; " \
                "bootm ${loadaddr}\0" \
        "findfdt="\
                "if test $board_name = sdp4430; then " \
index 1c1f8c0830d82de84fe15e3de39dd0491eb32332..189ea7e9140e33465b98f2e8b62b0db262801f37 100644 (file)
@@ -70,6 +70,7 @@
 #define CONFIG_ENV_VARS_UBOOT_RUNTIME_CONFIG
 #define CONFIG_EXTRA_ENV_SETTINGS \
        DEFAULT_LINUX_BOOT_ENV \
+       DEFAULT_MMC_TI_ARGS \
        "console=" CONSOLEDEV ",115200n8\0" \
        "fdtfile=undefined\0" \
        "bootpart=0:2\0" \
        "partitions=" PARTS_DEFAULT "\0" \
        "optargs=\0" \
        "dofastboot=0\0" \
-       "mmcdev=0\0" \
-       "mmcroot=/dev/mmcblk0p2 rw\0" \
-       "mmcrootfstype=ext4 rootwait\0" \
-       "mmcargs=setenv bootargs console=${console} " \
-               "${optargs} " \
-               "vram=${vram} " \
-               "root=${mmcroot} " \
-               "rootfstype=${mmcrootfstype}\0" \
        "loadbootscript=fatload mmc ${mmcdev} ${loadaddr} boot.scr\0" \
        "bootscript=echo Running bootscript from mmc${mmcdev} ...; " \
                "source ${loadaddr}\0" \
                        "if run loadimage; then " \
                                "run loadfdt; " \
                                "echo Booting from mmc${mmcdev} ...; " \
-                               "run mmcargs; " \
+                               "run args_mmc; " \
                                "bootz ${loadaddr} - ${fdtaddr}; " \
                        "fi;" \
                "fi;\0" \