[PATCH v1 1/2] aarch64: enable access to TCR2_ELx
Joey Gouly
joey.gouly at arm.com
Thu Jun 15 09:03:33 PDT 2023
Hi,
On Thu, Jun 15, 2023 at 04:21:06PM +0100, Mark Rutland wrote:
> On Fri, Mar 10, 2023 at 05:36:56PM +0000, Joey Gouly wrote:
> > Allow access the TCR2_ELx register which provides extended translation
> > controls similar to TCR_ELx.
>
> AFAICT TCR2_ELx reset to UNKNOWN values, and existing EL{2,1} software won't
> know that TCR2_ELx exists. So either:
>
> (a) The bootwrapper needs to initialize TCR2_ELx to some sane value to avoid
> subsequent problems.
>
> (b) The TCR2_ELx bits are gated by some existing RESx bit that EL{2,1} will
> configure (e.g. only apply after setting some existing TCR_ELx or SCTLR_Elx
> bit).
>
> I suspect that we fall into case (a), but I don't see any initialization of
> TCR2_ELx.
You're right, I will intialise it (to 0, seems like the right thing to do looking
at the definition) and send out a new series (along with the other fix).
>
> Do we need to add initiailization, or does case (b) apply? If it's the latter,
> could we please add something to the commit message describing that?
Looks like HCRX_EL2 is also missing initialisation.
>
> Other than that, this looks fine to me.
Thanks,
Joey
More information about the linux-arm-kernel
mailing list