From: Khalid Ali <khaliidcaliy@gmail.com>
To: ardb@kernel.org, paul.walmsley@sifive.com, palmer@dabbelt.com,
aou@eecs.berkeley.edu
Cc: alex@ghiti.fr, jonathan@marek.ca, chenhuacai@kernel.org,
jiaxun.yang@flygoat.com, viro@zeniv.linux.org.uk,
gourry@gourry.net, ilias.apalodimas@linaro.org, lukas@wunner.de,
gargaditya08@live.com, kees@kernel.org,
linux-efi@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-riscv@lists.infradead.org,
Khalid Ali <khaliidcaliy@gmail.com>
Subject: [PATCH v3 1/2] efi/libstub: Print error message if efi_allocate_bootparams() fails
Date: Sun, 6 Jul 2025 16:58:28 +0000 [thread overview]
Message-ID: <20250706165850.1090-1-khaliidcaliy@gmail.com> (raw)
From: Khalid Ali <khaliidcaliy@gmail.com>
Print error message in case efi_allocate_bootparams() fails before exit.
Change the direct call of efi_exit() to "goto fail". This allows the
general error message in fail label to get printed.
Signed-off-by: Khalid Ali <khaliidcaliy@gmail.com>
---
drivers/firmware/efi/libstub/x86-stub.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/firmware/efi/libstub/x86-stub.c b/drivers/firmware/efi/libstub/x86-stub.c
index cafc90d4caaf..13d8eba06e4b 100644
--- a/drivers/firmware/efi/libstub/x86-stub.c
+++ b/drivers/firmware/efi/libstub/x86-stub.c
@@ -824,7 +824,7 @@ void __noreturn efi_stub_entry(efi_handle_t handle,
if (!IS_ENABLED(CONFIG_EFI_HANDOVER_PROTOCOL) || !boot_params) {
status = efi_allocate_bootparams(handle, &boot_params);
if (status != EFI_SUCCESS)
- efi_exit(handle, status);
+ goto fail;
}
hdr = &boot_params->hdr;
--
2.49.0
_______________________________________________
linux-riscv mailing list
linux-riscv@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-riscv
next reply other threads:[~2025-07-06 17:01 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-07-06 16:58 Khalid Ali [this message]
2025-07-06 17:02 ` [PATCH v3 2/2] efi/libstub: Print uefi status code on error messages Khalid Ali
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=20250706165850.1090-1-khaliidcaliy@gmail.com \
--to=khaliidcaliy@gmail.com \
--cc=alex@ghiti.fr \
--cc=aou@eecs.berkeley.edu \
--cc=ardb@kernel.org \
--cc=chenhuacai@kernel.org \
--cc=gargaditya08@live.com \
--cc=gourry@gourry.net \
--cc=ilias.apalodimas@linaro.org \
--cc=jiaxun.yang@flygoat.com \
--cc=jonathan@marek.ca \
--cc=kees@kernel.org \
--cc=linux-efi@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-riscv@lists.infradead.org \
--cc=lukas@wunner.de \
--cc=palmer@dabbelt.com \
--cc=paul.walmsley@sifive.com \
--cc=viro@zeniv.linux.org.uk \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox