[U-Boot] [RFC] cmd: add bootslot command to select/boot slot based on boot counts

Sean Nyekjær sean.nyekjaer at prevas.dk
Fri Aug 24 11:13:28 UTC 2018


>> With RAUC bootslot's is specified with uppercase letters, uppercase is 
>> not preserved.
>> We end up with BOOT_b_LEFT=2...
>> botocmd_* is with lowercase, just to make things easier.
> 
> I cannot reproduce the lowercase issue. Can you send me your (def)config 
> and environment?
> 
> % grep BOOTSLOT .config
> CONFIG_CMD_BOOTSLOT=y
> CONFIG_CMD_BOOTSLOT_ENV_SLOTS="BOOTORDER"
> CONFIG_CMD_BOOTSLOT_ENV_COUNT="BOOT_%s_LEFT"
> CONFIG_CMD_BOOTSLOT_ENV_CMD="BOOTCMD_%s"
> CONFIG_CMD_BOOTSLOT_DEFAULT_COUNT=3
> 
> % grep -i boot board/raspberrypi/rpi/env.txt
> BOOTORDER=A B
> bootargs_all=console=ttyS0,115200n8 rootfstype=squashfs rootwait
> bootargs_a=root=/dev/mmcblk0p2 bootslot=A
> bootargs_b=root=/dev/mmcblk0p3 bootslot=B
> set_bootargs_a=setenv bootargs $bootargs_all $bootargs_a
> set_bootargs_b=setenv bootargs $bootargs_all $bootargs_b
> bootcmd_common=run load_kernel; booti $loadaddr - $fdtcontroladdr
> BOOTCMD_A=run set_bootargs_a bootcmd_common
> BOOTCMD_B=run set_bootargs_b bootcmd_common
> bootcmd=bootslot boot

Hi,

I'm not able to reproduce the lowercase issue, I must have got the 
config wrong :-)

Please submit a [PATCH] for this as it could be very useful.

/Sean


More information about the U-Boot mailing list