Received: by 2002:ab2:7041:0:b0:1f4:bcc8:f211 with SMTP id x1csp171086lql; Fri, 12 Apr 2024 07:07:19 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCUrNOmk1Bt044t+LGkU9f9PfrggenxK3T/kxAjD47Aa5rM5HjwGJIfVvNVzo4onMWMzNGH5mZQlC1JJSGe9OKSBM+k1cH4F8HrIPKb1pQ== X-Google-Smtp-Source: AGHT+IFYE9JEZ5XgEQ+oTRet0Tbppi9rPFuMjxnkO6UqOrDjBh9/xJjwlRNUHHdHltZnkh/drUMV X-Received: by 2002:a17:90a:db8e:b0:2a2:9001:94bf with SMTP id h14-20020a17090adb8e00b002a2900194bfmr2762327pjv.14.1712930839040; Fri, 12 Apr 2024 07:07:19 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1712930839; cv=pass; d=google.com; s=arc-20160816; b=1BS+K7i0CcTt+HRV44p79MqSISU2JOqhYjsQNSsQx2zPzbTY/Sq6/yMxbFP5GgoYYH aRSGnchbOOGoc8VIBldvSJQ5yWj+W/6nV/VRh0rHbXtglM/nzOBoRZjWxp58lTD6ZZ9P JpGEICAxkTaPsPZ4HmoxXcvXpzHys5G2Ot5ZlAObr9G5nELM6naSn8t2GtDFbDJEPRAQ 7lBxy6JV7xyb0+xYXtwhAJa/T7nAjJgv8D0+9AK9DjxWewsExCrcROZR4QNfWs/Uw8te hOBZG/UX9vHxqvnuoQa7Lqdsvh8zCIBG+7V1y46rC/3ko+RTzYyQLDITijGo3IXLEid8 2slA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=user-agent:in-reply-to:content-disposition:mime-version :list-unsubscribe:list-subscribe:list-id:precedence:references :message-id:subject:to:from:date:dkim-signature; bh=BFKyWMsUtOSQ8EbIWqFKxiCK6A8fCXI6OkG58xJuJLs=; fh=NJw3e6HCK47Zwf0HhoZbFDjYdtum8NhdcSnYB3oC9U0=; b=UZkQpdVIKO3A7FO59FDikpACU6XfBYTOoNTAAttYNZGeBjVhOO58gLWKsKm+ftKQsu k6XNbSMJCP6od43qv3h5DyuaojQD8SNzgqWM1vlE9xhx4U9sZiYW1g0bPo7YVcccHBi4 nZk4jmMARKNU+gcEtvQGzgrlY9ZPhlGLJP7TPuXIHbtlR+MrtUpPoHfkrc+7Ju1vt+1G s9LN6rxWo2ADYZ6nsWfPwuwrTPoQ4VoJz8w6Mds7GXKorhiWYq29LOGyI17Bwivs2NtG jzdEDGLp/b6nn9cn66uejFy2b6QXwrOgOXbR4ecYqjVV/PQsJcbJgkJVM9zxAdrMa9SB G4yg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=Rdsm4wWM; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-142782-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-142782-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [147.75.48.161]) by mx.google.com with ESMTPS id pc6-20020a17090b3b8600b002a21269c4fdsi5676999pjb.119.2024.04.12.07.07.18 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 12 Apr 2024 07:07:19 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-142782-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) client-ip=147.75.48.161; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=Rdsm4wWM; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-142782-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-142782-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sy.mirrors.kernel.org (Postfix) with ESMTPS id D0954B21EB4 for ; Fri, 12 Apr 2024 13:59:55 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 3C7D78593A; Fri, 12 Apr 2024 13:59:49 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="Rdsm4wWM" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 6341750241; Fri, 12 Apr 2024 13:59:48 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712930388; cv=none; b=jnBpiYGP/JUUtqqDUSNPXWOri6UL4cNBoPIhhAvi91KmHJZuDa21OPnWo0KYLLq3OYWWvaJsUibE3XEppdfEPH0sJPHzS8pnpYUnn878Ka2MrO33bqH/VH8lVu1ugVz/6zo2ZjQSJpZbclgkeIc+2n8bBNgUzLXc/MyTTZ7BkHo= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712930388; c=relaxed/simple; bh=C99AA46+hvRTtGxy3XR5W1R/6pmDxUu9xBGnM02STvk=; h=Date:From:To:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=UObsYCgtilVOznZt18nrH79zZOSkRmgwk7ybkZte/jnjYrz+pSoP+zIbawc4LRXHHdtrGRHVRIdJ0GXuHNkbD+MSqpDuG4woaxn0X4G9iDFF1zrgt8jZAWTS1KRUqoXE/cbbk25V6xwTLxaSkzhEuZA9w6STlWR6Fit6tMQAbtQ= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=Rdsm4wWM; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id A7DCDC2BD10; Fri, 12 Apr 2024 13:59:46 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1712930388; bh=C99AA46+hvRTtGxy3XR5W1R/6pmDxUu9xBGnM02STvk=; h=Date:From:To:Subject:References:In-Reply-To:From; b=Rdsm4wWMk8OGENFAWQJMUQ3jg7//LUF2BXzZ+tZwd4eQmlyho1CrXN9vMlFie6uid zzCaWvTPDe2uLER1Ctb1Jfv1j+g25uOZ9vfXV8CTJecRQausksZ733VDydUlYvkhuT 1uFedZE1+kjuTsDVnTK3AIvApw9ExaqxVSsH6G7+bQ0pNeIkpbTX6wEjJM0m3G5I0e UsP0LCqhx8M4RwnWBQCNCxDBGuI+E69Jv1wZvdS09FVOjvWGKPNP5SYmKEfgl4pyXL 9QRJWAywnO0JsMdcmK1yIL9sIRYFnm7rRvJoMdU4TQr4hadEm2XwMMD7Ia2gHnzaXe gEHyfb6iJZrXQ== Date: Fri, 12 Apr 2024 14:59:43 +0100 From: Will Deacon To: Andrea della Porta , Jonathan Corbet , Catalin Marinas , linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: Re: [PATCH v2] arm64: Add the arm64.no32bit_el0 command line option Message-ID: <20240412135942.GB28004@willie-the-truck> References: <20240207105847.7739-1-andrea.porta@suse.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) On Tue, Mar 05, 2024 at 11:56:05AM +0100, Andrea della Porta wrote: > On 11:58 Wed 07 Feb , Andrea della Porta wrote: > > Introducing the field 'el0' to the idreg-override for register > > ID_AA64PFR0_EL1. This field is also aliased to the new kernel > > command line option 'arm64.no32bit_el0' as a more recognizable > > and mnemonic name to disable the execution of 32 bit userspace > > applications (i.e. avoid Aarch32 execution state in EL0) from > > kernel command line. > > > > Changes in V2: > > - fixed the order of appearance of arm64.no32bit_el0 entry in > > kernel-parameters.txt documentation. > > > > Link: https://lore.kernel.org/r/ZVTleETzfFUchs77@apocalypse > > Signed-off-by: Andrea della Porta > > --- > > Documentation/admin-guide/kernel-parameters.txt | 3 +++ > > arch/arm64/kernel/idreg-override.c | 2 ++ > > 2 files changed, 5 insertions(+) > > > > diff --git a/Documentation/admin-guide/kernel-parameters.txt b/Documentation/admin-guide/kernel-parameters.txt > > index 65731b060e3f..fa7cdf2f4f3a 100644 > > --- a/Documentation/admin-guide/kernel-parameters.txt > > +++ b/Documentation/admin-guide/kernel-parameters.txt > > @@ -415,6 +415,9 @@ > > arcrimi= [HW,NET] ARCnet - "RIM I" (entirely mem-mapped) cards > > Format: ,, > > > > + arm64.no32bit_el0 [ARM64] Unconditionally disable the execution of > > + 32 bit applications > > + > > arm64.nobti [ARM64] Unconditionally disable Branch Target > > Identification support > > > > diff --git a/arch/arm64/kernel/idreg-override.c b/arch/arm64/kernel/idreg-override.c > > index e30fd9e32ef3..642cda19e42d 100644 > > --- a/arch/arm64/kernel/idreg-override.c > > +++ b/arch/arm64/kernel/idreg-override.c > > @@ -86,6 +86,7 @@ static const struct ftr_set_desc pfr0 __prel64_initconst = { > > .override = &id_aa64pfr0_override, > > .fields = { > > FIELD("sve", ID_AA64PFR0_EL1_SVE_SHIFT, pfr0_sve_filter), > > + FIELD("el0", ID_AA64PFR0_EL1_EL0_SHIFT, NULL), > > {} > > }, > > }; > > @@ -197,6 +198,7 @@ static const struct { > > { "arm64.nomops", "id_aa64isar2.mops=0" }, > > { "arm64.nomte", "id_aa64pfr1.mte=0" }, > > { "nokaslr", "arm64_sw.nokaslr=1" }, > > + { "arm64.no32bit_el0", "id_aa64pfr0.el0=1" }, > > }; > > > > static int __init parse_hexdigit(const char *p, u64 *v) > > -- > > 2.41.0 > > > > A gentle ping about this patch... any thoughts about it? It looks reasonable to me, but arch/arm64/kernel/idreg-override.c no longer exists upstream, so you need to rebase. Thanks, Will