* [PATCH v2] xilinx: zynqmp: Allow multiboot environment write even in saved environment
@ 2024-05-29 10:01 Kory Maincent
2024-05-29 13:02 ` Michal Simek
0 siblings, 1 reply; 2+ messages in thread
From: Kory Maincent @ 2024-05-29 10:01 UTC (permalink / raw)
To: u-boot
Cc: Kory Maincent, thomas.petazzoni, Michal Simek, Tom Rini,
Venkatesh Yadav Abbarapu
Once the environment was saved, the current multiboot image information
became unreachable. When dealing with firmware updates, this information
is necessary alongside the saved environment to know the booted image.
Move the multiboot environment set operation before the saved environment
check to ensure this information is always available.
Signed-off-by: Kory Maincent <kory.maincent@bootlin.com>
---
Change in v2:
- Fix nit in the commit message
---
board/xilinx/zynqmp/zynqmp.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/board/xilinx/zynqmp/zynqmp.c b/board/xilinx/zynqmp/zynqmp.c
index f370fb7347a..16292ed1c7e 100644
--- a/board/xilinx/zynqmp/zynqmp.c
+++ b/board/xilinx/zynqmp/zynqmp.c
@@ -519,6 +519,10 @@ int board_late_init(void)
usb_ether_init();
#endif
+ multiboot = multi_boot();
+ if (multiboot >= 0)
+ env_set_hex("multiboot", multiboot);
+
if (!(gd->flags & GD_FLG_ENV_DEFAULT)) {
debug("Saved variables - Skipping\n");
return 0;
@@ -531,10 +535,6 @@ int board_late_init(void)
if (ret)
return ret;
- multiboot = multi_boot();
- if (multiboot >= 0)
- env_set_hex("multiboot", multiboot);
-
if (IS_ENABLED(CONFIG_DISTRO_DEFAULTS)) {
ret = boot_targets_setup();
if (ret)
--
2.34.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH v2] xilinx: zynqmp: Allow multiboot environment write even in saved environment
2024-05-29 10:01 [PATCH v2] xilinx: zynqmp: Allow multiboot environment write even in saved environment Kory Maincent
@ 2024-05-29 13:02 ` Michal Simek
0 siblings, 0 replies; 2+ messages in thread
From: Michal Simek @ 2024-05-29 13:02 UTC (permalink / raw)
To: Kory Maincent, u-boot
Cc: thomas.petazzoni, Tom Rini, Venkatesh Yadav Abbarapu
On 5/29/24 12:01, Kory Maincent wrote:
> Once the environment was saved, the current multiboot image information
> became unreachable. When dealing with firmware updates, this information
> is necessary alongside the saved environment to know the booted image.
>
> Move the multiboot environment set operation before the saved environment
> check to ensure this information is always available.
>
> Signed-off-by: Kory Maincent <kory.maincent@bootlin.com>
> ---
>
> Change in v2:
> - Fix nit in the commit message
> ---
> board/xilinx/zynqmp/zynqmp.c | 8 ++++----
> 1 file changed, 4 insertions(+), 4 deletions(-)
>
> diff --git a/board/xilinx/zynqmp/zynqmp.c b/board/xilinx/zynqmp/zynqmp.c
> index f370fb7347a..16292ed1c7e 100644
> --- a/board/xilinx/zynqmp/zynqmp.c
> +++ b/board/xilinx/zynqmp/zynqmp.c
> @@ -519,6 +519,10 @@ int board_late_init(void)
> usb_ether_init();
> #endif
>
> + multiboot = multi_boot();
> + if (multiboot >= 0)
> + env_set_hex("multiboot", multiboot);
> +
> if (!(gd->flags & GD_FLG_ENV_DEFAULT)) {
> debug("Saved variables - Skipping\n");
> return 0;
> @@ -531,10 +535,6 @@ int board_late_init(void)
> if (ret)
> return ret;
>
> - multiboot = multi_boot();
> - if (multiboot >= 0)
> - env_set_hex("multiboot", multiboot);
> -
> if (IS_ENABLED(CONFIG_DISTRO_DEFAULTS)) {
> ret = boot_targets_setup();
> if (ret)
Applied.
M
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2024-05-29 13:02 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-05-29 10:01 [PATCH v2] xilinx: zynqmp: Allow multiboot environment write even in saved environment Kory Maincent
2024-05-29 13:02 ` Michal Simek
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox