On 4/27/20 11:48 AM, AKASHI Takahiro wrote:
> If this option is enabled, the initialisation of UEFI subsystem will be
> done as part of U-Boot initialisation.
>
> This feature will be utilised in implementing capsule-on-disk feature.

This would mean that we allow unaligned access very early. Something
Siarhei was against:

https://lists.denx.de/pipermail/u-boot/2018-March/324242.html
https://patchwork.ozlabs.org/project/uboot/patch/20180329213350.7868-1-xypron.g...@gmx.de/

Why can't you wait with the capsule update until any command initializes
the UEFI sub-system.

Best regards

Heinrich

>
> Signed-off-by: AKASHI Takahiro <takahiro.aka...@linaro.org>
> ---
>  common/board_r.c       | 6 ++++++
>  lib/efi_loader/Kconfig | 4 ++++
>  2 files changed, 10 insertions(+)
>
> diff --git a/common/board_r.c b/common/board_r.c
> index 0bbeaa7594c6..7cf21a6078f9 100644
> --- a/common/board_r.c
> +++ b/common/board_r.c
> @@ -64,6 +64,9 @@
>  #if defined(CONFIG_GPIO_HOG)
>  #include <asm/gpio.h>
>  #endif
> +#ifdef CONFIG_EFI_SETUP_EARLY
> +#include <efi_loader.h>
> +#endif
>
>  DECLARE_GLOBAL_DATA_PTR;
>
> @@ -867,6 +870,9 @@ static init_fnc_t init_sequence_r[] = {
>  #endif
>  #if defined(CONFIG_M68K) && defined(CONFIG_BLOCK_CACHE)
>       blkcache_init,
> +#endif
> +#ifdef CONFIG_EFI_SETUP_EARLY
> +     (init_fnc_t)efi_init_obj_list,
>  #endif
>       run_main_loop,
>  };
> diff --git a/lib/efi_loader/Kconfig b/lib/efi_loader/Kconfig
> index 1cfa24ffcf72..7cc2d940f848 100644
> --- a/lib/efi_loader/Kconfig
> +++ b/lib/efi_loader/Kconfig
> @@ -25,6 +25,10 @@ config EFI_LOADER
>
>  if EFI_LOADER
>
> +config EFI_SETUP_EARLY
> +     bool
> +     default n
> +
>  config EFI_GET_TIME
>       bool "GetTime() runtime service"
>       depends on DM_RTC
>

Reply via email to