summaryrefslogtreecommitdiff
path: root/drivers/firmware/efi/efi-pstore.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2020-07-25 13:18:42 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2020-07-25 13:18:42 -0700
commit17baa442864254cb2aadf3a4d668c0f81d2f07c5 (patch)
tree49fe525f402cecaab84d804963314f6967c5dcce /drivers/firmware/efi/efi-pstore.c
parent7cb3a5c5f6478ac0c14d01e35bc49e0ba7525e21 (diff)
parent74f85551666fe40bd739e95b5ecb20f53f8ad4df (diff)
downloadlwn-17baa442864254cb2aadf3a4d668c0f81d2f07c5.tar.gz
lwn-17baa442864254cb2aadf3a4d668c0f81d2f07c5.zip
Merge tag 'efi-urgent-2020-07-25' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip into master
Pull EFI fixes from Ingo Molnar: "Various EFI fixes: - Fix the layering violation in the use of the EFI runtime services availability mask in users of the 'efivars' abstraction - Revert build fix for GCC v4.8 which is no longer supported - Clean up some x86 EFI stub details, some of which are borderline bugs that copy around garbage into padding fields - let's fix these out of caution. - Fix build issues while working on RISC-V support - Avoid --whole-archive when linking the stub on arm64" * tag 'efi-urgent-2020-07-25' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: efi: Revert "efi/x86: Fix build with gcc 4" efi/efivars: Expose RT service availability via efivars abstraction efi/libstub: Move the function prototypes to header file efi/libstub: Fix gcc error around __umoddi3 for 32 bit builds efi/libstub/arm64: link stub lib.a conditionally efi/x86: Only copy upto the end of setup_header efi/x86: Remove unused variables
Diffstat (limited to 'drivers/firmware/efi/efi-pstore.c')
-rw-r--r--drivers/firmware/efi/efi-pstore.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/drivers/firmware/efi/efi-pstore.c b/drivers/firmware/efi/efi-pstore.c
index c2f1d4e6630b..feb7fe6f2da7 100644
--- a/drivers/firmware/efi/efi-pstore.c
+++ b/drivers/firmware/efi/efi-pstore.c
@@ -356,10 +356,7 @@ static struct pstore_info efi_pstore_info = {
static __init int efivars_pstore_init(void)
{
- if (!efi_rt_services_supported(EFI_RT_SUPPORTED_VARIABLE_SERVICES))
- return 0;
-
- if (!efivars_kobject())
+ if (!efivars_kobject() || !efivar_supports_writes())
return 0;
if (efivars_pstore_disable)