[PATCH v2 2/7] common: binman: Calling initr_binman() when BINMAN_FDT

Simon Glass sjg at chromium.org
Fri Dec 6 20:20:52 CET 2024


On Fri, 1 Nov 2024 at 03:18, Michal Simek <michal.simek at amd.com> wrote:
>
> Calling empty function when BINMAN_FDT is adding +64B for nothing which is
> not helping on size sensitive configurations as Xilinx mini configurations.
>
> Signed-off-by: Michal Simek <michal.simek at amd.com>
> ---
>
> Changes in v2:
> - new patch
>
> From my perspective there is no reason to call empty function. It is just
> increase footprint for nothing and we are not far from that limit now.
>
> ---
>  common/board_r.c | 7 +++----
>  1 file changed, 3 insertions(+), 4 deletions(-)

Reviewed-by: Simon Glass <sjg at chromium.org>

This is a bit odd, though. Do you have LTO enabled?




>
> diff --git a/common/board_r.c b/common/board_r.c
> index 62228a723e12..ff9bce88dc93 100644
> --- a/common/board_r.c
> +++ b/common/board_r.c
> @@ -287,13 +287,10 @@ static int initr_announce(void)
>         return 0;
>  }
>
> -static int initr_binman(void)
> +static int __maybe_unused initr_binman(void)
>  {
>         int ret;
>
> -       if (!CONFIG_IS_ENABLED(BINMAN_FDT))
> -               return 0;
> -
>         ret = binman_init();
>         if (ret)
>                 printf("binman_init failed:%d\n", ret);
> @@ -635,7 +632,9 @@ static init_fnc_t init_sequence_r[] = {
>  #ifdef CONFIG_EFI_LOADER
>         efi_memory_init,
>  #endif
> +#ifdef CONFIG_BINMAN_FDT
>         initr_binman,
> +#endif
>  #ifdef CONFIG_FSP_VERSION2
>         arch_fsp_init_r,
>  #endif
> --
> 2.43.0
>


More information about the U-Boot mailing list