From: Jia He <justin.he@arm.com>
To: Ard Biesheuvel <ardb@kernel.org>
Cc: Huacai Chen <chenhuacai@kernel.org>,
linux-efi@vger.kernel.org, linux-kernel@vger.kernel.org,
Alexandru Elisei <alexandru.elisei@arm.com>,
Jia He <justin.he@arm.com>
Subject: [PATCH 1/2] efi: libstub: Fix the retriving of supported rutime services
Date: Tue, 31 Jan 2023 04:03:54 +0000 [thread overview]
Message-ID: <20230131040355.3116-2-justin.he@arm.com> (raw)
In-Reply-To: <20230131040355.3116-1-justin.he@arm.com>
If retrieving UEFI configuration table is failed, the supported runtime
services mask should be regarded as 0 instead of EFI_RT_SUPPORTED_ALL.
Otherwise efi_novamap might be incorrectly assigned to "false" on the
Ampere Emag server.
Signed-off-by: Jia He <justin.he@arm.com>
---
drivers/firmware/efi/libstub/efi-stub.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/firmware/efi/libstub/efi-stub.c b/drivers/firmware/efi/libstub/efi-stub.c
index 2955c1ac6a36..f24b5436729c 100644
--- a/drivers/firmware/efi/libstub/efi-stub.c
+++ b/drivers/firmware/efi/libstub/efi-stub.c
@@ -111,6 +111,8 @@ static u32 get_supported_rt_services(void)
rt_prop_table = get_efi_config_table(EFI_RT_PROPERTIES_TABLE_GUID);
if (rt_prop_table)
supported &= rt_prop_table->runtime_services_supported;
+ else
+ supported = 0;
return supported;
}
--
2.25.1
next prev parent reply other threads:[~2023-01-31 4:04 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-01-31 4:03 [PATCH 0/2] Fix boot hang issue on Ampere Emag server Jia He
2023-01-31 4:03 ` Jia He [this message]
2023-01-31 7:04 ` [PATCH 1/2] efi: libstub: Fix the retriving of supported rutime services Ard Biesheuvel
2023-01-31 4:03 ` [PATCH 2/2] efi: Introduce efi_get_supported_rt_services() to get the runtime services mask Jia He
2023-01-31 7:06 ` Ard Biesheuvel
2023-01-31 7:18 ` [PATCH 0/2] Fix boot hang issue on Ampere Emag server Ard Biesheuvel
2023-01-31 15:21 ` Justin He
2023-01-31 15:31 ` Justin He
2023-01-31 18:23 ` Jason A. Donenfeld
2023-02-02 10:50 ` Justin He
2023-02-07 3:21 ` Justin He
2023-02-07 8:44 ` Ard Biesheuvel
2023-02-07 8:49 ` Justin He
2023-02-07 8:54 ` Ard Biesheuvel
2023-02-07 9:02 ` Justin He
2023-02-07 9:03 ` Ard Biesheuvel
2023-02-07 9:08 ` Justin He
2023-02-07 9:09 ` Ard Biesheuvel
2023-02-08 3:10 ` Justin He
2023-01-31 18:03 ` Jason A. Donenfeld
2023-01-31 18:13 ` Jason A. Donenfeld
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=20230131040355.3116-2-justin.he@arm.com \
--to=justin.he@arm.com \
--cc=alexandru.elisei@arm.com \
--cc=ardb@kernel.org \
--cc=chenhuacai@kernel.org \
--cc=linux-efi@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
/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.