From mboxrd@z Thu Jan 1 00:00:00 1970 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 CF5961991BB; Fri, 16 Aug 2024 11:13:34 +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=1723806814; cv=none; b=J/kPfpRpDcmP/2ggP9Dq8T0vM0f3JrNcMq+igOhm+HMUpgYFN3rK1mzrd9Nabe0zwfu87/yR8eh4Arx1O0TLfijIa2YjsAnK2nNS7elcuhCQIhvfdFaCPNOj8flEh4hnzRyEkQ/mutnRbHTKs7Y8QA6Tt1nxzYvOlaJasapqZ7w= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1723806814; c=relaxed/simple; bh=64cM9bclDSiB1iWfcpkQfUsDnt/GE+0NUolbKcBVzv0=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=azNd8/O5ZXDXP288RafUh2Hki45an05vqYT0bE5t++IERAfbjbipYvBX98yTmhV9yzCkPWjuX8sxXR0vVBJqXHypRScZYCgvWyp9Pd+BaLZX+SlR92wS8Np/AZBeARa5GkuipH6ZeEyli8MAEqSpjI01p1JAGTXL9s7p6/hXKBE= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 0B2CEC32782; Fri, 16 Aug 2024 11:13:28 +0000 (UTC) Date: Fri, 16 Aug 2024 12:13:27 +0100 From: Catalin Marinas To: Mark Brown Cc: Will Deacon , Jonathan Corbet , Andrew Morton , Marc Zyngier , Oliver Upton , James Morse , Suzuki K Poulose , Arnd Bergmann , Oleg Nesterov , Eric Biederman , Shuah Khan , "Rick P. Edgecombe" , Deepak Gupta , Ard Biesheuvel , Szabolcs Nagy , Kees Cook , "H.J. Lu" , Paul Walmsley , Palmer Dabbelt , Albert Ou , Florian Weimer , Christian Brauner , Thiago Jung Bauermann , Ross Burton , linux-arm-kernel@lists.infradead.org, linux-doc@vger.kernel.org, kvmarm@lists.linux.dev, linux-fsdevel@vger.kernel.org, linux-arch@vger.kernel.org, linux-mm@kvack.org, linux-kselftest@vger.kernel.org, linux-kernel@vger.kernel.org, linux-riscv@lists.infradead.org Subject: Re: [PATCH v10 09/40] arm64/gcs: Provide basic EL2 setup to allow GCS usage at EL0 and EL1 Message-ID: References: <20240801-arm64-gcs-v10-0-699e2bd2190b@kernel.org> <20240801-arm64-gcs-v10-9-699e2bd2190b@kernel.org> Precedence: bulk X-Mailing-List: linux-doc@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: <20240801-arm64-gcs-v10-9-699e2bd2190b@kernel.org> On Thu, Aug 01, 2024 at 01:06:36PM +0100, Mark Brown wrote: > There is a control HCRX_EL2.GCSEn which must be set to allow GCS > features to take effect at lower ELs and also fine grained traps for GCS > usage at EL0 and EL1. Configure all these to allow GCS usage by EL0 and > EL1. > > We also initialise GCSCR_EL1 and GCSCRE0_EL1 to ensure that we can > execute function call instructions without faulting regardless of the > state when the kernel is started. > > Signed-off-by: Mark Brown Reviewed-by: Catalin Marinas