diff options
author | Quentin Schulz <quentin.schulz@theobroma-systems.com> | 2024-01-17 18:59:13 +0100 |
---|---|---|
committer | Kever Yang <kever.yang@rock-chips.com> | 2024-01-19 10:57:36 +0800 |
commit | d2c90bfc4c56b8366b3c4c6ed298b0d81846fc7e (patch) | |
tree | f2de0ad75847476f6915b3b101aa4034b01b6325 /arch/arm/mach-stm32mp/cmd_stm32prog/stm32prog.h | |
parent | 87d3c472a266261642ad26a3d4b040de09edac71 (diff) |
rockchip: theobroma-systems: fix modified boot_targets detection
U-Boot proper automatically modifies boot_targets to swap the order in
which MMC storage media are used for standard boot based on which MMC
storage medium was used to load U-Boot proper. This is however only done
if the user has not changed it manually, therefore a check between the
default and current value is done.
This used to work fine until the migration to standard boot where
boot_targets value size in the default environment went above the 32
characters that env_get_default function can return, thus resulting in a
truncated variable.
Therefore the check between default and current value would always fail.
By using the newly added env_get_default_into function, a buffer of
the appropriate size can be allocated on the stack to get the whole
value of boot_targets in the default environment and thus fixing the
check.
Cc: Quentin Schulz <foss+uboot@0leil.net>
Reviewed-by: Kever Yang <kever.yang@rock-chips.com>
Signed-off-by: Quentin Schulz <quentin.schulz@theobroma-systems.com>
Diffstat (limited to 'arch/arm/mach-stm32mp/cmd_stm32prog/stm32prog.h')
0 files changed, 0 insertions, 0 deletions