From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-15.5 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,NICE_REPLY_A,SPF_HELO_NONE,SPF_PASS, URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 916EAC433DB for ; Fri, 12 Mar 2021 11:18:29 +0000 (UTC) Received: from desiato.infradead.org (desiato.infradead.org [90.155.92.199]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 3863C64F09 for ; Fri, 12 Mar 2021 11:18:29 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 3863C64F09 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=arm.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=desiato.20200630; h=Sender:Content-Transfer-Encoding :Content-Type:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:Date:Message-ID:From: References:Cc:To:Subject:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=BCfJqamabH4eaC5bdFieV5CqOXcBb5jVbUvOw3dY4cU=; b=I7Hwk7C20rXj25tgCDxQtReAd Ehde42DleMVsAnuCO3QCz3R51HcYozfeF81gAF5Iumwh/C6tDALnwJwod+tyyTF8hwFZQbyM5VkiL lF0001tIKlj4+lPKHHH1h+dscKB/wBiA4bJv8DWi+WUR7UuasP81ygVsZuVQgkswuTCXmOM9EN49Y f6z2ymJVqcQhPuAjtPYAUBV2rIPUfzYj5dWUqJrxpiNtRvAIGYrleFzTNTwUkloeE5lGsxOW/4fcQ /oReE6NHj5kwFJt9qPtyM2sspstIARX2C6lbnTF/JVGY5yR6A2R5FMviNNHA2KFLmS0fsFGl3trhP /QEeijX8A==; Received: from localhost ([::1] helo=desiato.infradead.org) by desiato.infradead.org with esmtp (Exim 4.94 #2 (Red Hat Linux)) id 1lKfmt-00BGzv-Iv; Fri, 12 Mar 2021 11:16:59 +0000 Received: from foss.arm.com ([217.140.110.172]) by desiato.infradead.org with esmtp (Exim 4.94 #2 (Red Hat Linux)) id 1lKfmo-00BGz5-JX for linux-arm-kernel@lists.infradead.org; Fri, 12 Mar 2021 11:16:56 +0000 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id AC031ED1; Fri, 12 Mar 2021 03:16:51 -0800 (PST) Received: from [10.57.15.100] (unknown [10.57.15.100]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 65E633F793; Fri, 12 Mar 2021 03:16:50 -0800 (PST) Subject: Re: [PATCH v3 1/2] arm64: Support execute-only permissions with Enhanced PAN To: Will Deacon Cc: linux-arm-kernel@lists.infradead.org, keescook@chromium.org, dave.martin@arm.com, catalin.marinas@arm.com References: <20210119160723.116983-1-vladimir.murzin@arm.com> <20210119160723.116983-2-vladimir.murzin@arm.com> <20210126110305.GA29467@willie-the-truck> From: Vladimir Murzin Message-ID: <867b9fe8-8882-2d21-254a-1ea8744adac1@arm.com> Date: Fri, 12 Mar 2021 11:17:04 +0000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.8.0 MIME-Version: 1.0 In-Reply-To: <20210126110305.GA29467@willie-the-truck> Content-Language: en-US X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210312_111654_938579_E442BE13 X-CRM114-Status: GOOD ( 17.09 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On 1/26/21 11:03 AM, Will Deacon wrote: > On Tue, Jan 19, 2021 at 04:07:22PM +0000, Vladimir Murzin wrote: >> Enhanced Privileged Access Never (EPAN) allows Privileged Access Never >> to be used with Execute-only mappings. >> >> Absence of such support was a reason for 24cecc377463 ("arm64: Revert >> support for execute-only user mappings"). Thus now it can be revisited >> and re-enabled. >> >> Cc: Kees Cook >> Cc: Catalin Marinas >> Signed-off-by: Vladimir Murzin >> --- >> arch/arm64/Kconfig | 17 +++++++++++++++++ >> arch/arm64/include/asm/cpucaps.h | 3 ++- >> arch/arm64/include/asm/pgtable-prot.h | 5 +++-- >> arch/arm64/include/asm/pgtable.h | 14 +++++++++++++- >> arch/arm64/include/asm/sysreg.h | 3 ++- >> arch/arm64/kernel/cpufeature.c | 12 ++++++++++++ >> arch/arm64/mm/fault.c | 3 +++ >> 7 files changed, 52 insertions(+), 5 deletions(-) > > (please cc me on arm64 patches) Ah, surely I should have done that! snip... >> --- a/arch/arm64/include/asm/pgtable.h >> +++ b/arch/arm64/include/asm/pgtable.h >> @@ -114,7 +114,7 @@ extern unsigned long empty_zero_page[PAGE_SIZE / sizeof(unsigned long)]; >> >> #define pte_valid(pte) (!!(pte_val(pte) & PTE_VALID)) > > We used to have a useful comment here describing why we're looking at UXN. > > There was also one next to the protection_map[], which I think we should add > back. Noted. It seems that the rest has been covered by Catalin... Cheers Vladimir _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel