From: Mark Rutland Date: Mon, 25 Apr 2016 20:07:11 +0000 (+0100) Subject: x86/efi: Enable runtime call flag checking X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=9788375dc4cdc9c00645028384fb40402eab774f;p=GitHub%2Fmoto-9609%2Fandroid_kernel_motorola_exynos9610.git 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 fb085ce00bd2..78d1e7467eae 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 *, ...);