From patchwork Thu Sep 5 06:30:25 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Qixiang Xu X-Patchwork-Id: 13791779 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 39762CD4F4D for ; Thu, 5 Sep 2024 06:32:23 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:MIME-Version:Content-Type: Content-Transfer-Encoding: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=/s3xJKmuSw2QwU7qJX4msvKuk4TbPFTdHvDwsgrDnWE=; b=ikNBCvjuTemiVp0F+5v9WU/qBT Gwj1ka+T+xmKT3pokuF9VnE+JX748YxMMWhe4Ud5adYyviOhOAqR2y/G9gnPTGXHM+FyJYBSfRqYu 5fSRq5CTwfGX+qH/c4IM9YJrVp2HruPM+9dtAR8Yd2rK5JSQpUtcwuN+65ZS2eNUxuUpBHcLvoJSy W/H1L16U52ED7/RGtHL976egSp30sAD6DdT+gpZ2xFFcOvnNgnPrASGzxNtUicfHJqw8lMr30Ob3a BVnTdKY0L8sIl54odVwGJKolkKMubGrEFixlO0cpx6xsfHoBEuV3GrCa6/JGpMdeDG3l5IZCWbigj aZx69NMA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1sm62P-00000007BZm-0zSg; Thu, 05 Sep 2024 06:32:13 +0000 Received: from mail-tyzapc01olkn20800.outbound.protection.outlook.com ([2a01:111:f403:280c::800] helo=APC01-TYZ-obe.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1sm61R-00000007BRB-1tJD for linux-arm-kernel@lists.infradead.org; Thu, 05 Sep 2024 06:31:14 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=b5rU0o9mQppy3Ct6DqgsXX5+ksz1Nihj4kMmuJjbAMX/bxL4zmZwgqShFBWEDGxFv365qY1joRnI4omfqh9Djs7T5nkHL0Q0Ym/zJzP4erkcFya1BcLqLWQLev+1SbW29xfdiFpjtix6h22WoUyl887MmB4Zk7U/yeU+cXS98R6y9P1vTDNT4okUedIchNOkq68HmjAPUhWt+aziEPIUXFy4RA3WhfLeLp1YWWFqfUPeV7UjUjPZGMa5HTvVHJmq/9TveovWFnymJIRIBN1DB/7y5v1m+qX3S++j46jo2YjTXY2K8nadhgV8mzCmPKWHL7eooat0lw44dfU4Oos00A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; 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=/s3xJKmuSw2QwU7qJX4msvKuk4TbPFTdHvDwsgrDnWE=; b=YHrgbWCIU2r675QUV0SE5i8aXtoXm8+pd7Ac62JdMC6xdstR5BOYNCMU5HEKlqWs8ciNfsgVJJXwmMm43a/PjsE8N5P/RPWksDD6uSMIDMT0ZrVgidT3fh6cWyAAyGzvuUn07HHsg0Ml8FWHHD3qoZUek5vCi/zU7ZMNpo2AtED2WxxlO0sKt9orTC+P37IxflnBriyv6U5VMT/GHON6XQegxwbRJVhkeAKUAMZo1nBiSwep7J70RAuBhAkUO2+HElnn13ooTdyKXtsL/aWGHBHgNokNi2PCrZ3QHI5QFRmf5cVp9XriTvooU48QWYJKRXFNL2kyES/Nnyl2HrYhaA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=/s3xJKmuSw2QwU7qJX4msvKuk4TbPFTdHvDwsgrDnWE=; b=TkMB0ZSS1sLDCDwG22sxW891aS36VnLLoJaTz/AYPLgOSq2Jj83fmKEUjJzgPtUCVvyaO+jejyAjPNWoM0XGeRVgyPnuNQFM5kFjkNFgyiAGV2aDn9uifbNASacmsvRhVg88KadPfgjItf2pWrCs/6X2259Cb6OXks4mrQXonDnblNn6oV4QqV0RVIPDYuTIvmcMiB8FvzbC4kzK35F3YlEEq0/Fk0EevIEpPHcyo/NTE4cOjf1vUW9yPtz8yz5iVvyVC8vanZ4nDuybJmZaOEh5OtBtWum19sNp6Fe729eochSMTimMfJTXjzHjOzDg717z87C/2YqP/gbSbUt6kA== Received: from SEZPR04MB6319.apcprd04.prod.outlook.com (2603:1096:101:a6::7) by SEYPR04MB5737.apcprd04.prod.outlook.com (2603:1096:101:8b::8) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7918.27; Thu, 5 Sep 2024 06:30:54 +0000 Received: from SEZPR04MB6319.apcprd04.prod.outlook.com ([fe80::8a6:22f0:5560:f3b4]) by SEZPR04MB6319.apcprd04.prod.outlook.com ([fe80::8a6:22f0:5560:f3b4%4]) with mapi id 15.20.7918.024; Thu, 5 Sep 2024 06:30:54 +0000 From: qixiang.xu@outlook.com To: maz@kernel.org, oliver.upton@linux.dev, will@kernel.org Cc: linux-arm-kernel@lists.infradead.org, kvmarm@lists.linux.dev, linux-kernel@vger.kernel.org, Qxiang Xu Subject: [PATCH 0/1] KVM: arm64: Make nVHE ASLR conditional on cmdline nokaslr Date: Thu, 5 Sep 2024 14:30:25 +0800 Message-ID: X-Mailer: git-send-email 2.25.1 In-Reply-To: <20240905061659.3410362-1-qixiang.xu@outlook.com> References: <20240905061659.3410362-1-qixiang.xu@outlook.com> X-TMN: [agUejvEB6sA+Ns6IkMMR0Px5pUhf0/32] X-ClientProxiedBy: SG2P153CA0048.APCP153.PROD.OUTLOOK.COM (2603:1096:4:c6::17) To SEZPR04MB6319.apcprd04.prod.outlook.com (2603:1096:101:a6::7) X-Microsoft-Original-Message-ID: <20240905063026.3411766-1-qixiang.xu@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: SEZPR04MB6319:EE_|SEYPR04MB5737:EE_ X-MS-Office365-Filtering-Correlation-Id: e5726afd-87c0-493e-c6e6-08dccd744b71 X-Microsoft-Antispam: BCL:0;ARA:14566002|461199028|5072599009|8060799006|15080799006|19110799003|3430499032|440099028|3412199025|1710799026; X-Microsoft-Antispam-Message-Info: YOSsycq/tU0sMQxAaE7iAVxseWKNy5HO8gg7wD7nw5CxUR6dz+siskTR/K3RPJewhF/xn/rCkqMYXSCix5zErPzixGexLshVsN4GExOrp58ZJwjF96E4Ha2MSKgWUsiILq46mteLsXI7y376KPBSUj6nZTC3hTTEChKvz3dRrMJs7XfDC7lI570vHwf8MHUMQWn9xrZ5Ibc8TDFigwTyNkBq6gTuZHdv/u720BlTjh7SBVGHvlqXLZGZSxviS5ycS11clqw+FiETxZramkaAwmx+3NlHfJbgbLi4CdEtuJTg2ys1rwULjCkThhyrrOm6Q6sCgZb9efdkKmvGm8y7+lI/9h06DufW8Ay+5wz/Z6FdYQwaRX3lNJEhPguAC213P+9mfwDbhYojv6aZ8IV3sRSLju5IizibMtVh7MSoTlCbdpXeKMF8RhzHtdHy7AJRuzSs9ZEpptZSNYuZfu7sKFAApEd0yV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ocEbK6DV+22XFaz6p+uXJsspeWqNl9CR4opeRvlfndoq20lOV5muvftqkwSx9ymM6dxInFg/7HH4bPLmrpeuihiVYz4WTPIYhlqWuQWclv1DuzV/sLelLuPY0jvFljV7u6+A/oBeD4TskQd8OSDdAdEJA+sEnFm6QGewSeIpWVw2QwIsrABs/qamzAJnMMSXnIKKIaIPZjHysw1l+3y6L7ER9HXqvZQJNHOs6QWeAy2w1++UFqTHmj/1lOMJdj4OvpkA/HhM1SgYf/nLk5yKhlBhrudf7PE+zHKKmW7iYckCxAUZuetGQSSqMDADFMh3eD9UNE1ow5hqnXK+zI/lflXkQC8JMKN8rOoSzlvjgNHmJpnNIXmK2XtiZvDApc9HaXGwqj+uSwY65dy/9vQ5h3Fos4iFIMejT4/PSb/I7XvK1zIGIEANjB9XfqYiwrusK8OqPYey6dwpD/oxICpGqwtoiOOW7cNL7ijvrUqucYfGFZT3O1Zof9pIeSXE= X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: e5726afd-87c0-493e-c6e6-08dccd744b71 X-MS-Exchange-CrossTenant-AuthSource: SEZPR04MB6319.apcprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 05 Sep 2024 06:30:54.8331 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: SEYPR04MB5737 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240904_233113_496539_3368F18A X-CRM114-Status: UNSURE ( 7.75 ) X-CRM114-Notice: Please train this message. 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 From: Qxiang Xu The nokaslr option in the kernel command line cannot disable the hyp VA random tag. This patch allows nokaslr to also disable the use of a random tag for hyp VA. Qxiang Xu (1): KVM: arm64: Make nVHE ASLR conditional on nokaslr arch/arm64/kvm/va_layout.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)