Message ID | 20231027180850.1068089-9-joey.gouly@arm.com (mailing list archive) |
---|---|
State | New |
Headers | show
Return-Path: <owner-linux-mm@kvack.org> X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id CAB84C27C46 for <linux-mm@archiver.kernel.org>; Fri, 27 Oct 2023 18:09:26 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 639186B03DF; Fri, 27 Oct 2023 14:09:26 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 5C3526B03E0; Fri, 27 Oct 2023 14:09:26 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 4152A6B03E1; Fri, 27 Oct 2023 14:09:26 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0013.hostedemail.com [216.40.44.13]) by kanga.kvack.org (Postfix) with ESMTP id 2D33D6B03DF for <linux-mm@kvack.org>; Fri, 27 Oct 2023 14:09:26 -0400 (EDT) Received: from smtpin05.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay09.hostedemail.com (Postfix) with ESMTP id 0E4B780462 for <linux-mm@kvack.org>; Fri, 27 Oct 2023 18:09:26 +0000 (UTC) X-FDA: 81392028732.05.967366A Received: from foss.arm.com (foss.arm.com [217.140.110.172]) by imf15.hostedemail.com (Postfix) with ESMTP id 668FFA0004 for <linux-mm@kvack.org>; Fri, 27 Oct 2023 18:09:24 +0000 (UTC) Authentication-Results: imf15.hostedemail.com; dkim=none; spf=pass (imf15.hostedemail.com: domain of joey.gouly@arm.com designates 217.140.110.172 as permitted sender) smtp.mailfrom=joey.gouly@arm.com; dmarc=pass (policy=none) header.from=arm.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1698430164; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=sgV4AndAd6/NO9/4ic2BHYdTbhCHHX5oZ2R85t/amgM=; b=db5wSM88cX8cqX6aSjpf2yRAdH2mpx+c/pqDKKIhWmyzoNLPTmnfgy38tF+P9ApzEErptk gDgwb3Te9lzOXNXWdUny5HCFGw4yc/NQ7FzznwHjnAt+ilQUql0YeFRPjYhgM+BYI99nZu yzCY8j4nMBYV0JUCC7oq7B9SaQTZ3kk= ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1698430164; a=rsa-sha256; cv=none; b=0J4h+wNluMH5svOBgZY41sCO3cNSszZTJ9nZRpjRvsmbXRS0G6VzQhJo62zLRhMh72AVL1 ki8MEPwFfmZZTaqBCTKckjBSM0YHk+UZg5fPdO72PJ4w+b608Yn1q0twrKREsrTBwcYBAA K0fWml6OIwEZsWY3uqHXIwRaikSEf6A= ARC-Authentication-Results: i=1; imf15.hostedemail.com; dkim=none; spf=pass (imf15.hostedemail.com: domain of joey.gouly@arm.com designates 217.140.110.172 as permitted sender) smtp.mailfrom=joey.gouly@arm.com; dmarc=pass (policy=none) header.from=arm.com 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 5B9BF1570; Fri, 27 Oct 2023 11:10:05 -0700 (PDT) Received: from e124191.cambridge.arm.com (e124191.cambridge.arm.com [10.1.197.45]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 8DB763F64C; Fri, 27 Oct 2023 11:09:21 -0700 (PDT) From: Joey Gouly <joey.gouly@arm.com> To: linux-arm-kernel@lists.infradead.org Cc: akpm@linux-foundation.org, aneesh.kumar@linux.ibm.com, broonie@kernel.org, catalin.marinas@arm.com, dave.hansen@linux.intel.com, joey.gouly@arm.com, maz@kernel.org, oliver.upton@linux.dev, shuah@kernel.org, will@kernel.org, kvmarm@lists.linux.dev, linux-fsdevel@vger.kernel.org, linux-mm@kvack.org, linux-kselftest@vger.kernel.org, James Morse <james.morse@arm.com>, Suzuki K Poulose <suzuki.poulose@arm.com>, Zenghui Yu <yuzenghui@huawei.com> Subject: [PATCH v2 08/24] arm64: add POIndex defines Date: Fri, 27 Oct 2023 19:08:34 +0100 Message-Id: <20231027180850.1068089-9-joey.gouly@arm.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20231027180850.1068089-1-joey.gouly@arm.com> References: <20231027180850.1068089-1-joey.gouly@arm.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Rspamd-Queue-Id: 668FFA0004 X-Rspam-User: X-Stat-Signature: eajypep68uxoez9r9ou5gt3xrmna7mmk X-Rspamd-Server: rspam03 X-HE-Tag: 1698430164-851894 X-HE-Meta: U2FsdGVkX1+76VJLkpCRT/w4QiTQC5ba+kbi87I9Uk5ArGPY06d+oMk3PfLtBxu0dH/vK7kInsiOwBSBkUToQceZjsIsZzVPNG3WPbt3xU6hSckIZDytBp1oUzWIolge8sMkLbI6RVlA//p+ru48qFE8lllPH5flU6Cld6jWdwFAwlgE9Mn2k+GulbFetDIsJzmI4CDZ1Sl9zwpO6Ml6GWDwtZKmWnVqMDU//UgkDzkAafTrJ0QqO2pfRmQQD1IBAi9i7G/Xnhur4v5i6UC0QmRzX7ItqzLBTa3/nWZvCT89ahIJXgre4kZiSuieuCWrdmhlnzJ1kZEQexsbuGwaSgXfSVskiLS4vUqG4vU2bTR1UcmJIqUO17Ka4l2Hw+jEkl4g/KBkx6fPvZyw5VCmSB8eF/J7U8M9D8RlZgb5qoAF38ag5Y+PGkyj04IndpcsPEXZmuGobkhth1FN6PBJInIlqJ1CUncgICMs0t6KXPc7UTgCiM12/ILKHvtGAPomaNW6ZFCRFf3jD4ImgqjL6LtVk2zsQb2dobxCUXDLfrjZzEGqUflmDXPYI0bZ6wj6pkiMVQkLo/2jaGorzkLoCiU/tJH5qoWQaB9mwPfdHTmFiVPAsj884PqNGN4cxgZm6KwP9s9jijBLQPrZ0R17/pbnbo4sqiBqL5CVT6Kxzit1gX2tn8J1HmZBO6sP4bLT1Mu1sAwouj16slf1YRwf1LsSfuXMX1g4QOhb/n4hy5p+Uvek0mKQJleVQ3ooQGfVLasjwk/zl/9COSgGBs44XCmDGpdOW+U0Y7fKt8TzAnPibAbQNeimY0Y8Kyvs68jP7gxRZbemGOvLPXaUiuTOr06zTffEm/dltHoJ5/eFgdJNJyGc/SDmyQJ/T8gLBfQbv4noVt+uEH+c52aDAqaYnjEgKJDXwQzrgU3OdkpLJoPu3fzHSaFOw1HaXk9QKglkYOgH3kifQpizFYLIaBL yu8HYMPA K5HN7rWVxsKJTarnLfGirkAwcu5Zy39LBtCoz45nv2ZjZpPrhklKF7tDgWXgiCrnspkoWt+L/YLuoUcSPIQUTFM8Si0FC/GsyINYezhsR4P2pSnxi3+VifO7oCLqVnkDnCxBkFpuwQcumF9/FzUoxJN4A2eGU+bNBUtK6wPx4Ew7dooUSmjvpUmOg1b8aCx0PlzWxvkKzbzWWd6DwMd3stQ7Bhw== X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: <linux-mm.kvack.org> List-Subscribe: <mailto:majordomo@kvack.org> List-Unsubscribe: <mailto:majordomo@kvack.org> |
Series |
Permission Overlay Extension
|
expand
|
diff --git a/arch/arm64/include/asm/pgtable-hwdef.h b/arch/arm64/include/asm/pgtable-hwdef.h index e4944d517c99..fe270fa39110 100644 --- a/arch/arm64/include/asm/pgtable-hwdef.h +++ b/arch/arm64/include/asm/pgtable-hwdef.h @@ -178,6 +178,16 @@ #define PTE_PI_IDX_2 53 /* PXN */ #define PTE_PI_IDX_3 54 /* UXN */ +/* + * POIndex[2:0] encoding (Permission Overlay Extension) + */ +#define PTE_PO_IDX_0 (_AT(pteval_t, 1) << 60) +#define PTE_PO_IDX_1 (_AT(pteval_t, 1) << 61) +#define PTE_PO_IDX_2 (_AT(pteval_t, 1) << 62) + +#define PTE_PO_IDX_MASK GENMASK_ULL(62, 60) + + /* * Memory Attribute override for Stage-2 (MemAttr[3:0]) */
The 3-bit POIndex is stored in the PTE at bits 60..62. Signed-off-by: Joey Gouly <joey.gouly@arm.com> Cc: Catalin Marinas <catalin.marinas@arm.com> Cc: Will Deacon <will@kernel.org> --- arch/arm64/include/asm/pgtable-hwdef.h | 10 ++++++++++ 1 file changed, 10 insertions(+)