artik710: configs: clear local variable after load_fdt
authorChanho Park <chanho61.park@samsung.com>
Thu, 22 Jun 2017 07:16:54 +0000 (16:16 +0900)
committerChanho Park <chanho61.park@samsung.com>
Thu, 22 Jun 2017 07:16:54 +0000 (16:16 +0900)
This patch clears local variables such as success, number and loop of
load_fdt command to avoid invalid environment corruption. After
execution "run load_fdt" command on the u-boot shell, it will keep the
local variables. When a user run "saveenv" command in the situation,
it will cause invalid fdt load due to dirty local variables.

Change-Id: I1788167e087a00001785015a952743db8d502c79
Signed-off-by: Chanho Park <chanho61.park@samsung.com>
include/configs/artik710_raptor.h

index 823a50d671a9ae7154768dbdcd4cdb9ae5741d7c..0ca26f48b0ae237509e02474662aeb45ca5fe4b9 100644 (file)
                        "ext4load mmc $rootdev:$bootpart $fdtaddr s5p6818-artik710-raptor-rev${number}.dtb; "   \
                "fi; "                                                  \
                "else ext4load mmc $rootdev:$bootpart $fdtaddr $fdtfile; " \
-               "fi;\0"                                                 \
+               "fi; setenv success; setenv number; setenv loop;\0"     \
        "bootdelay=" __stringify(CONFIG_BOOTDELAY) "\0"                 \
        "console=" CONFIG_DEFAULT_CONSOLE                               \
        "consoleon=setenv console=" CONFIG_DEFAULT_CONSOLE              \