From 9788375dc4cdc9c00645028384fb40402eab774f Mon Sep 17 00:00:00 2001 From: Mark Rutland Date: Mon, 25 Apr 2016 21:07:11 +0100 Subject: x86/efi: Enable runtime call flag checking Define ARCH_EFI_IRQ_FLAGS_MASK for x86, which will enable the generic runtime wrapper code to detect when firmware erroneously modifies flags over a runtime services function call. For x86 (both 32-bit and 64-bit), we only need check the interrupt flag. Signed-off-by: Mark Rutland Signed-off-by: Matt Fleming Cc: Ard Biesheuvel Cc: Ben Hutchings Cc: Borislav Petkov Cc: Catalin Marinas Cc: Christoph Hellwig Cc: Darren Hart Cc: David Herrmann Cc: David Howells Cc: Greg KH Cc: Hannes Reinecke Cc: Harald Hoyer harald@redhat.com Cc: James Bottomley Cc: Kweh Hock Leong Cc: Leif Lindholm Cc: Peter Jones Cc: Peter Zijlstra Cc: Raphael Hertzog Cc: Russell King Cc: Thomas Gleixner Cc: Will Deacon Cc: linux-efi@vger.kernel.org Link: http://lkml.kernel.org/r/1461614832-17633-40-git-send-email-matt@codeblueprint.co.uk Signed-off-by: Ingo Molnar diff --git a/arch/x86/include/asm/efi.h b/arch/x86/include/asm/efi.h index fb085ce..78d1e74 100644 --- a/arch/x86/include/asm/efi.h +++ b/arch/x86/include/asm/efi.h @@ -3,6 +3,7 @@ #include #include +#include #include /* @@ -28,8 +29,9 @@ #define MAX_CMDLINE_ADDRESS UINT_MAX -#ifdef CONFIG_X86_32 +#define ARCH_EFI_IRQ_FLAGS_MASK X86_EFLAGS_IF +#ifdef CONFIG_X86_32 extern unsigned long asmlinkage efi_call_phys(void *, ...); -- cgit v0.10.2