diff mbox series

configs: am335x_boneblack: Bring back missed bootcmd

Message ID 20171228210325.25376-1-semen.protsenko@linaro.org
State Accepted
Commit 48fa31206dba839eaa2df5dcca09fc0c8e3be1ff
Headers show
Series configs: am335x_boneblack: Bring back missed bootcmd | expand

Commit Message

Sam Protsenko Dec. 28, 2017, 9:03 p.m. UTC
Commit b6251db8c3f0 ("Kconfig: Introduce USE_BOOTCOMMAND and migrate
BOOTCOMMAND") removed CONFIG_BOOTCOMMAND option from
include/configs/am335x_evm.h file. But that option wasn't added to
defconfig files for BeagleBone Black board.

Because of this we can't boot Linux from SD card using just
"run bootcmd", getting next error:

    ** File not found /boot/undefined **

That's because "fdtfile" variable has "undefined" value by default, and
"bootcmd" doesn't call "run findfdt" command, which assigns "fdtfile" to
correct device tree file for current board name (obtained from EEPROM).

So we are forced to either call "run findfdt" command manually, or
assign manually "fdtfile=am335x-boneblack.dtb" (e.g. in uEnv.txt file).

Bring back CONFIG_BOOTCOMMAND to BBB defconfigs so that we can boot
Linux rootfs from SD card automatically without any addition actions.

Signed-off-by: Sam Protsenko <semen.protsenko@linaro.org>
---
 configs/am335x_boneblack_defconfig       | 1 +
 configs/am335x_boneblack_vboot_defconfig | 1 +
 2 files changed, 2 insertions(+)

Comments

Tom Rini Jan. 2, 2018, 12:47 a.m. UTC | #1
On Thu, Dec 28, 2017 at 11:03:25PM +0200, Sam Protsenko wrote:

> Commit b6251db8c3f0 ("Kconfig: Introduce USE_BOOTCOMMAND and migrate

> BOOTCOMMAND") removed CONFIG_BOOTCOMMAND option from

> include/configs/am335x_evm.h file. But that option wasn't added to

> defconfig files for BeagleBone Black board.

> 

> Because of this we can't boot Linux from SD card using just

> "run bootcmd", getting next error:

> 

>     ** File not found /boot/undefined **

> 

> That's because "fdtfile" variable has "undefined" value by default, and

> "bootcmd" doesn't call "run findfdt" command, which assigns "fdtfile" to

> correct device tree file for current board name (obtained from EEPROM).

> 

> So we are forced to either call "run findfdt" command manually, or

> assign manually "fdtfile=am335x-boneblack.dtb" (e.g. in uEnv.txt file).

> 

> Bring back CONFIG_BOOTCOMMAND to BBB defconfigs so that we can boot

> Linux rootfs from SD card automatically without any addition actions.

> 

> Signed-off-by: Sam Protsenko <semen.protsenko@linaro.org>


Applied to u-boot/master, thanks!

-- 
Tom
diff mbox series

Patch

diff --git a/configs/am335x_boneblack_defconfig b/configs/am335x_boneblack_defconfig
index 55e0ebd69c..50093cd662 100644
--- a/configs/am335x_boneblack_defconfig
+++ b/configs/am335x_boneblack_defconfig
@@ -5,6 +5,7 @@  CONFIG_AM33XX=y
 # CONFIG_SPL_NAND_SUPPORT is not set
 CONFIG_DISTRO_DEFAULTS=y
 CONFIG_SYS_EXTRA_OPTIONS="EMMC_BOOT"
+CONFIG_BOOTCOMMAND="if test ${boot_fit} -eq 1; then run update_to_fit; fi; run findfdt; run init_console; run envboot; run distro_bootcmd"
 CONFIG_SYS_CONSOLE_INFO_QUIET=y
 CONFIG_VERSION_VARIABLE=y
 CONFIG_ARCH_MISC_INIT=y
diff --git a/configs/am335x_boneblack_vboot_defconfig b/configs/am335x_boneblack_vboot_defconfig
index fe5b9e7622..aa9fb9739e 100644
--- a/configs/am335x_boneblack_vboot_defconfig
+++ b/configs/am335x_boneblack_vboot_defconfig
@@ -8,6 +8,7 @@  CONFIG_DISTRO_DEFAULTS=y
 CONFIG_FIT_SIGNATURE=y
 CONFIG_FIT_VERBOSE=y
 CONFIG_SYS_EXTRA_OPTIONS="EMMC_BOOT"
+CONFIG_BOOTCOMMAND="if test ${boot_fit} -eq 1; then run update_to_fit; fi; run findfdt; run init_console; run envboot; run distro_bootcmd"
 CONFIG_SYS_CONSOLE_INFO_QUIET=y
 CONFIG_VERSION_VARIABLE=y
 CONFIG_ARCH_MISC_INIT=y