From: sashiko-bot@kernel.org
To: "Ard Biesheuvel" <ardb+git@google.com>, linux-efi@vger.kernel.org
Cc: "Ard Biesheuvel" <ardb@kernel.org>,
"Jason Gunthorpe" <jgg@nvidia.com>,
"Paul Walmsley" <pjw@kernel.org>,
"Palmer Dabbelt" <palmer@dabbelt.com>,
"Albert Ou" <aou@eecs.berkeley.edu>,
"Huacai Chen" <chenhuacai@kernel.org>
Subject: Re: [PATCH v3 09/15] efi/libstub: loongarch: Use struct efi_image_info to access image properties
Date: Mon, 16 Nov 2026 14:40:27 +0000 [thread overview]
Message-ID: <sashiko-outbox-217185@kernel.org> (raw)
In-Reply-To: <20261116142618.1687025-26-ardb+git@google.com>
Thank you for your contribution! Sashiko AI review found 1 potential
issue to consider:
- [Low] efi/libstub: loongarch: dead declarations left after image_info
conversion
--
commit d80068564b9cb3b54d5e07eb729d7302295ab088
Author: Ard Biesheuvel <ardb@kernel.org>
efi/libstub: loongarch: Use struct efi_image_info to access image properties
This commit switches the LoongArch EFI stub to resolve the kernel entry
point through struct efi_image_info and drops kernel_entry_address() and
unused linker script symbol aliases.
> diff --git a/arch/loongarch/kernel/image-vars.h b/arch/loongarch/kernel/image-vars.h
> index e557ebd46c2b3..b01022ce6bb8a 100644
> --- a/arch/loongarch/kernel/image-vars.h
> +++ b/arch/loongarch/kernel/image-vars.h
> @@ -8,12 +8,8 @@
> #ifdef CONFIG_EFI_STUB
>
> __efistub_strcmp = strcmp;
> -__efistub_kernel_entry = kernel_entry;
> __efistub_kernel_asize = kernel_asize;
> __efistub_kernel_fsize = kernel_fsize;
> -#if defined(CONFIG_EFI_EARLYCON) || defined(CONFIG_SYSFB)
> -__efistub_sysfb_primary_display = sysfb_primary_display;
> -#endif
>
> #endif
>
> diff --git a/drivers/firmware/efi/libstub/loongarch-stub.c b/drivers/firmware/efi/libstub/loongarch-stub.c
> index d57e3d3557a54..6126b05e99fbe 100644
> --- a/drivers/firmware/efi/libstub/loongarch-stub.c
> +++ b/drivers/firmware/efi/libstub/loongarch-stub.c
> @@ -116,11 +116,3 @@ efi_status_t handle_kernel_image(unsigned long *image_addr,
> *(unsigned long *)image_info += *image_addr - (unsigned long)image->image_base;
> return status;
> }
> -
> -unsigned long kernel_entry_address(unsigned long kernel_addr,
> - efi_loaded_image_t *image)
> -{
> - unsigned long base = (unsigned long)image->image_base;
> -
> - return (unsigned long)&kernel_entry - base + kernel_addr;
> -}
[Severity: Low]
This isn't a bug, but removing kernel_entry_address() and
__efistub_kernel_entry leaves behind "extern int kernel_entry;" in
drivers/firmware/efi/libstub/loongarch-stub.c as well as
drivers/firmware/efi/libstub/loongarch-stub.h (which only declares
kernel_entry_address()) and its #include directives in loongarch-stub.c
and loongarch.c.
Also, should handle_kernel_image() use efistub_kernel_size(*image_info)
and efistub_kernel_memsize(*image_info) so that __efistub_kernel_fsize and
__efistub_kernel_asize can be dropped from
arch/loongarch/kernel/image-vars.h as well?
--
Sashiko AI review · https://sashiko.dev/#/patchset/20261116142618.1687025-17-ardb+git@google.com?part=9
next prev parent reply other threads:[~2026-11-16 14:40 UTC|newest]
Thread overview: 63+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-16 14:26 [PATCH v3 00/15] efi: Expose loaded image properties via info struct Ard Biesheuvel
2026-11-16 14:26 ` Ard Biesheuvel
2026-11-16 14:26 ` [PATCH v3 01/15] efi/zboot: arm64: Add missing barrier after cache maintenance Ard Biesheuvel
2026-11-16 14:26 ` Ard Biesheuvel
2026-11-16 14:33 ` sashiko-bot
2026-11-16 14:26 ` [PATCH v3 02/15] riscv: Use _stext not _text to denote the start of kernel code Ard Biesheuvel
2026-11-16 14:26 ` Ard Biesheuvel
2026-11-16 18:52 ` Jason Gunthorpe
2026-11-16 18:52 ` Jason Gunthorpe
2026-11-16 14:26 ` [PATCH v3 03/15] riscv: Make _text point to the start of the kernel image Ard Biesheuvel
2026-11-16 14:26 ` Ard Biesheuvel
2026-11-16 18:52 ` Jason Gunthorpe
2026-11-16 18:52 ` Jason Gunthorpe
2026-11-16 14:26 ` [PATCH v3 04/15] efi/riscv: Rename __init_text_end to __inittext_end like other archs Ard Biesheuvel
2026-11-16 14:26 ` Ard Biesheuvel
2026-11-16 14:26 ` [PATCH v3 05/15] efi/libstub: Avoid _end section marker in library code Ard Biesheuvel
2026-11-16 14:26 ` Ard Biesheuvel
2026-11-16 18:52 ` Jason Gunthorpe
2026-11-16 18:52 ` Jason Gunthorpe
2026-11-16 14:26 ` [PATCH v3 06/15] efi/libstub: Capture loaded image information in struct efi_image_info Ard Biesheuvel
2026-11-16 14:26 ` Ard Biesheuvel
2026-11-16 14:59 ` sashiko-bot
2026-11-16 18:52 ` Jason Gunthorpe
2026-11-16 18:52 ` Jason Gunthorpe
2026-11-16 14:26 ` [PATCH v3 07/15] efi/libstub: Pass kernel entrypoint down to efi_enter_kernel() Ard Biesheuvel
2026-11-16 14:26 ` Ard Biesheuvel
2026-11-16 14:39 ` sashiko-bot
2026-11-16 18:52 ` Jason Gunthorpe
2026-11-16 18:52 ` Jason Gunthorpe
2026-11-16 19:31 ` Ard Biesheuvel
2026-11-16 19:31 ` Ard Biesheuvel
2026-11-16 14:26 ` [PATCH v3 08/15] efi/libstub: arm64: Use struct efi_image_info to access image properties Ard Biesheuvel
2026-11-16 14:26 ` Ard Biesheuvel
2026-11-16 18:52 ` Jason Gunthorpe
2026-11-16 18:52 ` Jason Gunthorpe
2026-11-16 19:33 ` Ard Biesheuvel
2026-11-16 19:33 ` Ard Biesheuvel
2026-11-16 14:26 ` [PATCH v3 09/15] efi/libstub: loongarch: " Ard Biesheuvel
2026-11-16 14:26 ` Ard Biesheuvel
2026-11-16 14:40 ` sashiko-bot [this message]
2026-11-16 18:52 ` Jason Gunthorpe
2026-11-16 18:52 ` Jason Gunthorpe
2026-11-16 14:26 ` [PATCH v3 10/15] efi/libstub: riscv: " Ard Biesheuvel
2026-11-16 14:26 ` Ard Biesheuvel
2026-11-16 18:52 ` Jason Gunthorpe
2026-11-16 18:52 ` Jason Gunthorpe
2026-11-16 14:26 ` [PATCH v3 11/15] efi/libstub: Make efi_remap_image() return efi_status_t Ard Biesheuvel
2026-11-16 14:26 ` Ard Biesheuvel
2026-11-16 14:26 ` [PATCH v3 12/15] efi/zboot: Disentangle efi_remap_image() from efi_cache_sync_image() Ard Biesheuvel
2026-11-16 14:26 ` Ard Biesheuvel
2026-11-16 14:52 ` sashiko-bot
2026-11-16 14:26 ` [PATCH v3 13/15] efi/libstub: arm64: Drop zboot code_size hack Ard Biesheuvel
2026-11-16 14:26 ` Ard Biesheuvel
2026-11-16 14:26 ` [PATCH v3 14/15] efi: Make config table based primary display handover ARM-only again Ard Biesheuvel
2026-11-16 14:26 ` Ard Biesheuvel
2026-11-16 18:52 ` Jason Gunthorpe
2026-11-16 18:52 ` Jason Gunthorpe
2026-11-16 14:26 ` [PATCH v3 15/15] Revert "efi: earlycon: Reprobe after parsing config tables" Ard Biesheuvel
2026-11-16 14:26 ` Ard Biesheuvel
2026-11-16 18:52 ` Jason Gunthorpe
2026-11-16 18:52 ` Jason Gunthorpe
2026-11-16 18:52 ` [PATCH v3 00/15] efi: Expose loaded image properties via info struct Jason Gunthorpe
2026-11-16 18:52 ` Jason Gunthorpe
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=sashiko-outbox-217185@kernel.org \
--to=sashiko-bot@kernel.org \
--cc=aou@eecs.berkeley.edu \
--cc=ardb+git@google.com \
--cc=ardb@kernel.org \
--cc=chenhuacai@kernel.org \
--cc=jgg@nvidia.com \
--cc=linux-efi@vger.kernel.org \
--cc=palmer@dabbelt.com \
--cc=pjw@kernel.org \
--cc=sashiko-reviews@lists.linux.dev \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.