Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932927AbcDYNyV (ORCPT ); Mon, 25 Apr 2016 09:54:21 -0400 Received: from foss.arm.com ([217.140.101.70]:46615 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932066AbcDYNyR (ORCPT ); Mon, 25 Apr 2016 09:54:17 -0400 Date: Mon, 25 Apr 2016 14:54:09 +0100 From: Will Deacon To: Mark Rutland Cc: linux-efi@vger.kernel.org, ard.biesheuvel@linaro.org, catalin.marinas@arm.com, hpa@zytor.com, leif.lindholm@linaro.org, linux-arm-kernel@lists.infradead.org, linux@arm.linux.org.uk, linux-kernel@vger.kernel.org, matt@codeblueprint.co.uk, mingo@redhat.com, tglx@linutronix.de Subject: Re: [PATCHv3 2/5] arm64/efi: enable runtime call flag checking Message-ID: <20160425135409.GE30830@arm.com> References: <1461591994-14918-1-git-send-email-mark.rutland@arm.com> <1461591994-14918-3-git-send-email-mark.rutland@arm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1461591994-14918-3-git-send-email-mark.rutland@arm.com> User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1430 Lines: 42 On Mon, Apr 25, 2016 at 02:46:31PM +0100, Mark Rutland wrote: > Define ARCH_EFI_IRQ_FLAGS_MASK for arm64, which will enable the generic > runtime wrapper code to detect when firmware erroneously modifies flags > over a runtime services function call. > > Signed-off-by: Mark Rutland > Cc: Ard Biesheuvel > Cc: Catalin Marinas > Cc: Leif Lindholm > Cc: Matt Fleming > Cc: Will Deacon > Cc: linux-arm-kernel@lists.infradead.org > Cc: linux-efi@vger.kernel.org > --- > arch/arm64/include/asm/efi.h | 3 +++ > 1 file changed, 3 insertions(+) > > diff --git a/arch/arm64/include/asm/efi.h b/arch/arm64/include/asm/efi.h > index f4f71224..b44603e 100644 > --- a/arch/arm64/include/asm/efi.h > +++ b/arch/arm64/include/asm/efi.h > @@ -4,6 +4,7 @@ > #include > #include > #include > +#include > #include > > #ifdef CONFIG_EFI > @@ -33,6 +34,8 @@ int efi_create_mapping(struct mm_struct *mm, efi_memory_desc_t *md); > kernel_neon_end(); \ > }) > > +#define ARCH_EFI_IRQ_FLAGS_MASK (PSR_D_BIT | PSR_A_BIT | PSR_I_BIT | PSR_F_BIT) I look forward to the day when the firmware returns in big-endian AArch32 ;) Anyway, this looks good to me: Acked-by: Will Deacon Will