From patchwork Wed Sep 27 14:01:16 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Joey Gouly X-Patchwork-Id: 13400878 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 D609DE80AAC for ; Wed, 27 Sep 2023 14:04: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:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:CC:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=5fo33Pu7pO54GCjaPhAlJqtN0/sDWc4dOAjsvkE8UP8=; b=EVDwoeUKs3a5Lf rXYBb0Un3z7KmiOp7F/3p5lzxZVzk1cRyWCWQ7IHPMMycgtoBhcvhx1PqtoEN89kJrEsoHjdnIzmu 1vZbTaghdcTyZwZC/CjB4bzrMu9Eft8BhGEMNEanRFwTIIRhOxFNJmS/DbzjYoDT+eg5ms6dFzZga YhUXb/3VtjCgr6F8mqLFRUaGfQgMk6jql3WcXjAbZ8YmX7n8M46PujcmDqjYu7LDTbCyYnmP1+5yP UCNH2U0cagkk+t2zh0KaynX7pgGo9kjFrJP/+CTA6dgqKGk1ZyQsOg1573j1+Rdsurhr6ChkrO6jV Xqp4y6ErEGBz8g+vyVdA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1qlV8v-0014zQ-06; Wed, 27 Sep 2023 14:03:57 +0000 Received: from mail-db5eur01on061f.outbound.protection.outlook.com ([2a01:111:f400:fe02::61f] helo=EUR01-DB5-obe.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1qlV8s-0014xD-2F for linux-arm-kernel@lists.infradead.org; Wed, 27 Sep 2023 14:03:56 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=armh.onmicrosoft.com; s=selector2-armh-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=fP0hZBQLW0r5LPMNDw9vkQWBkTgVKFZIvfc9QkLlChM=; b=Yrx8MYtKqgv9lvFMg6MENe9rLixHTzZ+HgyngQg4Xu3XO/KXDeB/We1+Z9727+I3RgXDmySuAoquSk8F/fk7MC8hbGS0YLS5LiQs9vYzaUdB+3nklBpY/N1DFOD6PmZPizrtUjSF99GFTUBzNS0Mg18hb8R5/ccQvnyUJvIZcA4= Received: from AS9P194CA0028.EURP194.PROD.OUTLOOK.COM (2603:10a6:20b:46d::18) by PAWPR08MB8909.eurprd08.prod.outlook.com (2603:10a6:102:33a::19) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6813.28; Wed, 27 Sep 2023 14:03:47 +0000 Received: from AM7EUR03FT040.eop-EUR03.prod.protection.outlook.com (2603:10a6:20b:46d:cafe::d6) by AS9P194CA0028.outlook.office365.com (2603:10a6:20b:46d::18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6838.21 via Frontend Transport; Wed, 27 Sep 2023 14:03:47 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 63.35.35.123) smtp.mailfrom=arm.com; dkim=pass (signature was verified) header.d=armh.onmicrosoft.com;dmarc=pass action=none header.from=arm.com; Received-SPF: Pass (protection.outlook.com: domain of arm.com designates 63.35.35.123 as permitted sender) receiver=protection.outlook.com; client-ip=63.35.35.123; helo=64aa7808-outbound-1.mta.getcheckrecipient.com; pr=C Received: from 64aa7808-outbound-1.mta.getcheckrecipient.com (63.35.35.123) by AM7EUR03FT040.mail.protection.outlook.com (100.127.140.128) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6838.22 via Frontend Transport; Wed, 27 Sep 2023 14:03:46 +0000 Received: ("Tessian outbound 0ae75d4034ba:v211"); Wed, 27 Sep 2023 14:03:46 +0000 X-CheckRecipientChecked: true X-CR-MTA-CID: ae231f9e02a9b0cb X-CR-MTA-TID: 64aa7808 Received: from 42361384454a.1 by 64aa7808-outbound-1.mta.getcheckrecipient.com id 7EDF8468-9F69-4C21-BA86-2E1A1B912054.1; Wed, 27 Sep 2023 14:01:51 +0000 Received: from EUR05-AM6-obe.outbound.protection.outlook.com by 64aa7808-outbound-1.mta.getcheckrecipient.com with ESMTPS id 42361384454a.1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384); Wed, 27 Sep 2023 14:01:51 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=dPJCUUrZNNyO177ukqeVhbgMpCT3DoTiFQBkauYBSbcsjLQnQgayICGsdIlQh9CKb+DKgkWgpwZwIt0yLDOXkppkkLJQx/iofqdAhPR1AZ//EGi+9Wg/gKpNKJe9KF7eUTVLPWiTPh1xIfussZyc/1q1UlNlaUX2U+PI3IfBysPIEHlorOHNSYqHxBYdqEIjvqM8zuCJXbBU8nlnqtYWZXn0cPetWvL7dnqnYluVAZltr3QcclojYTFcLMn6CN4w3MRAxTN0T9vauLSr/+lowiJJEJMxHSIOjeAkvk9svzXtpdLDt7ILiA1mFTX5ckPpq3Ux0dy9uVIEmrqAC8Q6Mw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=fP0hZBQLW0r5LPMNDw9vkQWBkTgVKFZIvfc9QkLlChM=; b=N3ZJcDjUd1sbw5LgCA5Ljo9fzFb9wQPxto2aWnel/ldP6MGDO3bPDqAeeWWeq8ZgSDNO1B+bhbwuqz3T5W73VU1JS4OqH/0KgmsC2GI6cjRNAqdtVA/WvZwppwDZPsX8F5DMFtdZZHpOiWssvW3shHI+RDIBrWaiclzYGKfSTvliUCGXrrdNJOFy2PiHS2Sq5KADEEb4+/tsIi2mlYUW+fhBqdG3Dierm+FLAzv//R/Pjuatwb6NNRwSNZaHnMwHSDKcWICNC5t2NHHPhhgCQNdXzVHG0y80o73y04wTFCcxVFrXijvics2EqJbaROiVU095TzAgXVGu9GxJ/tUt+g== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 40.67.248.234) smtp.rcpttodomain=lists.infradead.org smtp.mailfrom=arm.com; dmarc=pass (p=none sp=none pct=100) action=none header.from=arm.com; dkim=none (message not signed); arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=armh.onmicrosoft.com; s=selector2-armh-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=fP0hZBQLW0r5LPMNDw9vkQWBkTgVKFZIvfc9QkLlChM=; b=Yrx8MYtKqgv9lvFMg6MENe9rLixHTzZ+HgyngQg4Xu3XO/KXDeB/We1+Z9727+I3RgXDmySuAoquSk8F/fk7MC8hbGS0YLS5LiQs9vYzaUdB+3nklBpY/N1DFOD6PmZPizrtUjSF99GFTUBzNS0Mg18hb8R5/ccQvnyUJvIZcA4= Received: from DB9PR05CA0009.eurprd05.prod.outlook.com (2603:10a6:10:1da::14) by AS4PR08MB7653.eurprd08.prod.outlook.com (2603:10a6:20b:4cf::5) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6813.28; Wed, 27 Sep 2023 14:01:49 +0000 Received: from DBAEUR03FT051.eop-EUR03.prod.protection.outlook.com (2603:10a6:10:1da:cafe::a3) by DB9PR05CA0009.outlook.office365.com (2603:10a6:10:1da::14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6838.21 via Frontend Transport; Wed, 27 Sep 2023 14:01:49 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 40.67.248.234) smtp.mailfrom=arm.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=arm.com; Received-SPF: Pass (protection.outlook.com: domain of arm.com designates 40.67.248.234 as permitted sender) receiver=protection.outlook.com; client-ip=40.67.248.234; helo=nebula.arm.com; pr=C Received: from nebula.arm.com (40.67.248.234) by DBAEUR03FT051.mail.protection.outlook.com (100.127.142.148) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.6838.21 via Frontend Transport; Wed, 27 Sep 2023 14:01:49 +0000 Received: from AZ-NEU-EX02.Emea.Arm.com (10.251.26.5) by AZ-NEU-EX03.Arm.com (10.251.24.31) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.27; Wed, 27 Sep 2023 14:01:40 +0000 Received: from AZ-NEU-EX03.Arm.com (10.251.24.31) by AZ-NEU-EX02.Emea.Arm.com (10.251.26.5) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.27; Wed, 27 Sep 2023 14:01:40 +0000 Received: from e124191.cambridge.arm.com (10.1.197.45) by mail.arm.com (10.251.24.31) with Microsoft SMTP Server id 15.1.2507.27 via Frontend Transport; Wed, 27 Sep 2023 14:01:39 +0000 From: Joey Gouly To: CC: , , , , , , , , , , , , , Subject: [PATCH v1 13/20] arm64: stop using generic mm_hooks.h Date: Wed, 27 Sep 2023 15:01:16 +0100 Message-ID: <20230927140123.5283-14-joey.gouly@arm.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20230927140123.5283-1-joey.gouly@arm.com> References: <20230927140123.5283-1-joey.gouly@arm.com> MIME-Version: 1.0 X-EOPAttributedMessage: 1 X-MS-TrafficTypeDiagnostic: DBAEUR03FT051:EE_|AS4PR08MB7653:EE_|AM7EUR03FT040:EE_|PAWPR08MB8909:EE_ X-MS-Office365-Filtering-Correlation-Id: 5ed612a3-4230-4f9b-6fb8-08dbbf629162 x-checkrecipientrouted: true NoDisclaimer: true X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam-Untrusted: BCL:0; X-Microsoft-Antispam-Message-Info-Original: du8ahLLIPeC9aWNg18cDj6DAuuvBKq7TIOCwkSO9W6bRQvyJ8x1dUN2enprZH2zUd1C6a5buJDsOSePUj+WJXweB4a+8l7RXJnCGukKSaRGTAhM9QGJSdEOF45cn5vIgmN5UhD08LlZb/jK6gbd+5rAkJv7zwxT/bfHKS3AQwgM1IelX0ckDQPKKQkwKgZ6gL7mmL6E/nv4AMvsbJ+t4zIB8UGfhqF6YWaBP0iNaT6JCPnjHA4EEtkI7WBlU54DrXZI+GgtA6dqLbeOHVrWlrFLjEcuTukEN2i9CCYWQ+3IJzEDEZinhMf+OPXUjXOpueiqW0elFhUfyoGHffJAotL0bzrcyYwvqtH6A0d44dICctd/tlBGe6bQLqTM8c6BO/kspiTD+UKjG4EQHKVckTlUKg6/43vbcnPrtI4AB4kkCbJGUa12I+Zhydz+2fPisjREOABuf9jLhUI2e7peT8BbJBsBk2FfBGUPJVaoeXby+Th/81Z5sQQ0OgW4uiVzkVEJlvLs4h4z3uzDIltD5EMUeogK0/J9/dBz+ufGGCWmvyBvh829lohATA2mJbJjCMDO8+WS2QlgRbWzJbzE0L+w/Dk3Syg7JJe/aSnluf6p1HSf1kwFuS3qWgmO69NT6rZxEeN7sExHW0Jdzo2auSviK9iar04gcpB5OZ1x8Z2sEMDsQ8s3nwiT8T5Q3uCYpThqF5rO/rrU21o+/k7BvUjTCTSU4Tm1+DoX5GTx45V6kfWNxAkvwxmz/oaS4Nly9fK59ysQAr/c5PwqlIYa1aeaiOwoG9Rmv2E8BARRPuHs= X-Forefront-Antispam-Report-Untrusted: CIP:40.67.248.234;CTRY:IE;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:nebula.arm.com;PTR:InfoDomainNonexistent;CAT:NONE;SFS:(13230031)(4636009)(376002)(39860400002)(396003)(346002)(136003)(230922051799003)(451199024)(186009)(82310400011)(1800799009)(36840700001)(40470700004)(46966006)(54906003)(316002)(70206006)(70586007)(6916009)(7416002)(40480700001)(8676002)(4326008)(41300700001)(8936002)(2906002)(44832011)(478600001)(40460700003)(26005)(6666004)(36860700001)(47076005)(83380400001)(5660300002)(7696005)(81166007)(426003)(2616005)(336012)(36756003)(1076003)(86362001)(82740400003)(356005)(41533002)(36900700001);DIR:OUT;SFP:1101; X-MS-Exchange-Transport-CrossTenantHeadersStamped: AS4PR08MB7653 X-MS-Exchange-Transport-CrossTenantHeadersStripped: AM7EUR03FT040.eop-EUR03.prod.protection.outlook.com X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id-Prvs: dce59fe5-efad-4c43-be7a-08dbbf624b62 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: AiV2DyftP0cO8/iRu08NUbcKOlZeU3S5TiKwLjM+MEXLmiasNq0/f0hqxaYZyQ0IFJVJIlLLqT7M8QEkKS8LtsryIqSaxdAVZKY7rEHzgyvmRU90GhUDWN43Bp3SEneaK/J7lLNEIhmQRi3s24sdXIc5FkvgXVxaoF5FTyLfxZMeoeAzaGaWk6qivYrof+MH1xGbpjgPzAcXjR90+AKvM+x2KFkWW6ZOVsPdYFIdGRacnsGTzbvw1vnBFtR5jgZxvaLVRN/YtAGMacKOILh7MvrlfZQi6ugck5iQNJUz6DvEXBsvuCu26cXw0wG9FcvmUD7VY8qNgoSS7x62QJQMrHaKNXgsMU/cdgkkBbcb2NrBWZAqsxuVVq+U2P295OYBYyYz5NSH/1vUp7zYY1g28XpZ+rmIvVPZ4BmCW+YXdjwXTmgnivq3aS0YWgFX323TQ3GMA+4bAFW/fQHrPcs4DFBC1EGOsI54kC4IuEJqscOIlY61iE0gPHXgfrcxtnF9nraj2BY0U/XqLfUigOV0x8XsYbq1EAYUTEtAt4RVv96y2wv/zdC9RHXnbwS7kIzoVsIKj3y0jraNIhFCkk1xFMjvb7RxqANEVGGflPmwXS6//zB1FTVgbhggTgPWCdDM9lr0zCzFgDU2rFrtPVkYjnh0SnkJ9afCHy/Aw2wFPb9+xP9oWzOjTaI/rQkpesl3nkEvrfycHnLpEwvuQmlmtbrKC+hn5dOf8ONqzCNtx8mjPQVMUbSN3RWSbrQCb1/KpzxqYKpMkBXOlJ0bcrmlDw== X-Forefront-Antispam-Report: CIP:63.35.35.123;CTRY:IE;LANG:en;SCL:1;SRV:;IPV:CAL;SFV:NSPM;H:64aa7808-outbound-1.mta.getcheckrecipient.com;PTR:ec2-63-35-35-123.eu-west-1.compute.amazonaws.com;CAT:NONE;SFS:(13230031)(4636009)(136003)(396003)(346002)(39860400002)(376002)(230922051799003)(451199024)(82310400011)(1800799009)(186009)(36840700001)(46966006)(40470700004)(86362001)(36756003)(40480700001)(6666004)(5660300002)(26005)(54906003)(70586007)(426003)(2616005)(1076003)(70206006)(336012)(6916009)(478600001)(8936002)(44832011)(4326008)(41300700001)(7696005)(107886003)(316002)(8676002)(2906002)(47076005)(40460700003)(82740400003)(81166007)(36860700001)(83380400001)(41533002);DIR:OUT;SFP:1101; X-OriginatorOrg: arm.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 27 Sep 2023 14:03:46.9279 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 5ed612a3-4230-4f9b-6fb8-08dbbf629162 X-MS-Exchange-CrossTenant-Id: f34e5979-57d9-4aaa-ad4d-b122a662184d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=f34e5979-57d9-4aaa-ad4d-b122a662184d;Ip=[63.35.35.123];Helo=[64aa7808-outbound-1.mta.getcheckrecipient.com] X-MS-Exchange-CrossTenant-AuthSource: AM7EUR03FT040.eop-EUR03.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: PAWPR08MB8909 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230927_070354_742087_E558265D X-CRM114-Status: GOOD ( 12.04 ) 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: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org These functions will be extended to support pkeys. Signed-off-by: Joey Gouly Cc: Catalin Marinas Cc: Will Deacon --- arch/arm64/include/asm/mmu_context.h | 21 ++++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) diff --git a/arch/arm64/include/asm/mmu_context.h b/arch/arm64/include/asm/mmu_context.h index a6fb325424e7..c0eeed54225e 100644 --- a/arch/arm64/include/asm/mmu_context.h +++ b/arch/arm64/include/asm/mmu_context.h @@ -20,7 +20,6 @@ #include #include #include -#include #include #include #include @@ -209,6 +208,20 @@ init_new_context(struct task_struct *tsk, struct mm_struct *mm) return 0; } +static inline int arch_dup_mmap(struct mm_struct *oldmm, struct mm_struct *mm) +{ + return 0; +} + +static inline void arch_exit_mmap(struct mm_struct *mm) +{ +} + +static inline void arch_unmap(struct mm_struct *mm, + unsigned long start, unsigned long end) +{ +} + #ifdef CONFIG_ARM64_SW_TTBR0_PAN static inline void update_saved_ttbr0(struct task_struct *tsk, struct mm_struct *mm) @@ -298,6 +311,12 @@ static inline unsigned long mm_untag_mask(struct mm_struct *mm) return -1UL >> 8; } +static inline bool arch_vma_access_permitted(struct vm_area_struct *vma, + bool write, bool execute, bool foreign) +{ + return true; +} + #include #endif /* !__ASSEMBLY__ */