diff mbox series

[v2,01/12] KVM: Add missing HCRX_EL2 field definitions

Message ID 20231206100503.564090-2-tabba@google.com (mailing list archive)
State New, archived
Headers show
Series KVM: arm64: Fixes to fine grain traps and pKVM traps | expand

Commit Message

Fuad Tabba Dec. 6, 2023, 10:04 a.m. UTC
Add the latest field definitions to HCRX_EL2 from the 2023-09 Arm
Architecture System Registers xml specification [*].

These fields aren't used yet. This is done mainly to get the
correct generated value for the register's RES0 mask.

[*] https://developer.arm.com/documentation/ddi0601/2023-09/AArch64-Registers/HCRX-EL2--Extended-Hypervisor-Configuration-Register

Signed-off-by: Fuad Tabba <tabba@google.com>
---
 arch/arm64/tools/sysreg | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

Comments

Mark Brown Dec. 7, 2023, 4:57 p.m. UTC | #1
On Wed, Dec 06, 2023 at 10:04:51AM +0000, Fuad Tabba wrote:
> Add the latest field definitions to HCRX_EL2 from the 2023-09 Arm
> Architecture System Registers xml specification [*].
> 
> These fields aren't used yet. This is done mainly to get the
> correct generated value for the register's RES0 mask.

> ---
>  arch/arm64/tools/sysreg | 4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)

This isn't a KVM specific patch, this is an arch patch - I'd have
expected a subject line "arm64/sysreg:" or something...

>  Sysreg	HCRX_EL2	3	4	1	2	2
> -Res0	63:23
> +Res0	63:25
> +Field	24	PACMEn
> +Field	23	EnFPM
>  Field	22	GCSEn
>  Field	21	EnIDCP128
>  Field	20	EnSDERR

This is the same as my equivalent patch in the 2023 dpISA series:

   https://lore.kernel.org/linux-arm-kernel/20231205-arm64-2023-dpisa-v3-7-dbcbcd867a7f@kernel.org/

Reviewed-by: Mark Brown <broonie@kernel.org>

(that series does make use of EnFPM).  Given the likelyhood of overlaps
like this I really think we should be merging these sysreg updates even
if the serieses that depend on them are still in flight, it doesn't make
sense for multiple people to end up doing the typing.
Fuad Tabba Dec. 8, 2023, 8:14 a.m. UTC | #2
Hi Mark,

Thanks for your reviews!

On Thu, Dec 7, 2023 at 4:57 PM Mark Brown <broonie@kernel.org> wrote:
>
> On Wed, Dec 06, 2023 at 10:04:51AM +0000, Fuad Tabba wrote:
> > Add the latest field definitions to HCRX_EL2 from the 2023-09 Arm
> > Architecture System Registers xml specification [*].
> >
> > These fields aren't used yet. This is done mainly to get the
> > correct generated value for the register's RES0 mask.
>
> > ---
> >  arch/arm64/tools/sysreg | 4 +++-
> >  1 file changed, 3 insertions(+), 1 deletion(-)
>
> This isn't a KVM specific patch, this is an arch patch - I'd have
> expected a subject line "arm64/sysreg:" or something...

Sorry. That was the intention, instead of removing the KVM for my
"KVM:arm64"s I removed the arm. Will fix it on the respin.

>
> >  Sysreg       HCRX_EL2        3       4       1       2       2
> > -Res0 63:23
> > +Res0 63:25
> > +Field        24      PACMEn
> > +Field        23      EnFPM
> >  Field        22      GCSEn
> >  Field        21      EnIDCP128
> >  Field        20      EnSDERR
>
> This is the same as my equivalent patch in the 2023 dpISA series:
>
>    https://lore.kernel.org/linux-arm-kernel/20231205-arm64-2023-dpisa-v3-7-dbcbcd867a7f@kernel.org/
>
> Reviewed-by: Mark Brown <broonie@kernel.org>
>
> (that series does make use of EnFPM).  Given the likelyhood of overlaps
> like this I really think we should be merging these sysreg updates even
> if the serieses that depend on them are still in flight, it doesn't make
> sense for multiple people to end up doing the typing.

Makes sense. We'll ask one of the maintainers to pick up your updates.

Cheers,
/fuad
Mark Brown Dec. 8, 2023, 1:43 p.m. UTC | #3
On Fri, Dec 08, 2023 at 08:14:58AM +0000, Fuad Tabba wrote:
> On Thu, Dec 7, 2023 at 4:57 PM Mark Brown <broonie@kernel.org> wrote:

> > (that series does make use of EnFPM).  Given the likelyhood of overlaps
> > like this I really think we should be merging these sysreg updates even
> > if the serieses that depend on them are still in flight, it doesn't make
> > sense for multiple people to end up doing the typing.

> Makes sense. We'll ask one of the maintainers to pick up your updates.

Thanks.  I'm in the middle of pulling a series together which gathers
all the sysreg additions I'm aware of together which are ready
(including yours from this series) - should be out later today unless
something unexpected happens in my CI, hopefully one way or another
everything will get pulled in.  I'll Cc you when I post.
diff mbox series

Patch

diff --git a/arch/arm64/tools/sysreg b/arch/arm64/tools/sysreg
index 96cbeeab4eec..c6cc8f2396e6 100644
--- a/arch/arm64/tools/sysreg
+++ b/arch/arm64/tools/sysreg
@@ -2300,7 +2300,9 @@  Fields	ZCR_ELx
 EndSysreg
 
 Sysreg	HCRX_EL2	3	4	1	2	2
-Res0	63:23
+Res0	63:25
+Field	24	PACMEn
+Field	23	EnFPM
 Field	22	GCSEn
 Field	21	EnIDCP128
 Field	20	EnSDERR