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 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 19522C76195 for ; Mon, 27 Mar 2023 16:48:25 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=a5yUTwSCMRzZSBdeHxOqWASNrndpCry40Jd8kUw4v7s=; b=1wWYba/QzapFoo DpEewtyjsE2DvTH8bVEuIkyk6gEHOEi8OS8wKElL96m6p9cdSx3bDe4OGUcsvxJuuoKMQVGJmu9wO YM2I1GBJSmCrRzG8S/qV2xSj91lPl953rDmJNvfbj98/N3fT010CsJ8PrX3HzGtTpNqh90/0NvIGi snxW6VWpxwhVHh/RRSC+qWTedX5hx1x3etxlao6u0wYSSb5FNAbqbbtW+6gSJEdiILpsO9ymAizgS esN8dZzksk82RZcq9bUh8JDc+eLbuCN5/zYupvw4M4FHHh/sLoOUerWbGNBE20yOrm9H3qo3cM6SS SR2ILtkoXW8CT1XS4uLA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1pgq0O-00Bk5v-1w; Mon, 27 Mar 2023 16:47:36 +0000 Received: from dfw.source.kernel.org ([139.178.84.217]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1pgq0M-00Bk5W-0D for linux-arm-kernel@lists.infradead.org; Mon, 27 Mar 2023 16:47:35 +0000 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 70C34613F7; Mon, 27 Mar 2023 16:47:33 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id EE711C433EF; Mon, 27 Mar 2023 16:47:30 +0000 (UTC) Date: Mon, 27 Mar 2023 17:47:28 +0100 From: Catalin Marinas To: Joey Gouly Cc: linux-arm-kernel@lists.infradead.org, nd@arm.com, broonie@kernel.org, james.morse@arm.com, mark.rutland@arm.com, maz@kernel.org, oliver.upton@linux.dev, suzuki.poulose@arm.com, will@kernel.org, yuzenghui@huawei.com Subject: Re: [PATCH v1 13/18] arm64: add PTE_WRITE to PROT_SECT_NORMAL Message-ID: References: <20230309145246.22787-1-joey.gouly@arm.com> <20230309145246.22787-14-joey.gouly@arm.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20230309145246.22787-14-joey.gouly@arm.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230327_094734_141024_55DBEF7E X-CRM114-Status: GOOD ( 10.25 ) 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 Thu, Mar 09, 2023 at 02:52:41PM +0000, Joey Gouly wrote: > With PIE enabled, PROT_SECT_NORMAL would map onto PAGE_KERNEL_RO. > Add PTE_WRITE so that this maps onto PAGE_KERNEL, so that it is writable. > > Without PIE, this should enable DBM for PROT_SECT_NORMAL, which should be > functionally equivalent. It's worth mentioning that since PTE_RDONLY (a.k.a. PTE_NDIRTY with PIE) is already cleared, we don't even rely on the DBM mechanism to make it writable. Reviewed-by: Catalin Marinas _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel