[PATCH] efi_loader: Use sysreset instead of reset command

Heinrich Schuchardt xypron.glpk at gmx.de
Tue Mar 15 11:26:29 CET 2022


On 3/15/22 01:43, Masami Hiramatsu wrote:
> Use sysreset_walk_halt() directly from reset-after-capsule-on-disk
> feature to reboot (cold reset) machine instead of using reset command
> interface, since this is not a command.

As long as not all UEFI supported boards use sysreset you cannot do this
change. See wandboard_defconfig.

Best regards

Heinrich

>
> Signed-off-by: Masami Hiramatsu <masami.hiramatsu at linaro.org>
> ---
>   lib/efi_loader/efi_capsule.c |    4 ++--
>   1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/lib/efi_loader/efi_capsule.c b/lib/efi_loader/efi_capsule.c
> index 613b531b82..35907ad0d2 100644
> --- a/lib/efi_loader/efi_capsule.c
> +++ b/lib/efi_loader/efi_capsule.c
> @@ -1150,9 +1150,9 @@ efi_status_t efi_launch_capsules(void)
>   	 * UEFI spec requires to reset system after complete processing capsule
>   	 * update on the storage.
>   	 */
> -	log_info("Reboot after firmware update");
> +	log_info("Reboot after firmware update.\n");
>   	/* Cold reset is required for loading the new firmware. */
> -	do_reset(NULL, 0, 0, NULL);
> +	sysreset_walk_halt(SYSRESET_COLD);
>   	hang();
>   	/* not reach here */
>
>



More information about the U-Boot mailing list