]> www.infradead.org Git - users/jedix/linux-maple.git/commit
KVM: arm64: Properly save/restore HCRX_EL2
authorMarc Zyngier <maz@kernel.org>
Wed, 30 Apr 2025 10:59:15 +0000 (11:59 +0100)
committerOliver Upton <oliver.upton@linux.dev>
Wed, 7 May 2025 07:16:44 +0000 (00:16 -0700)
commitffea7c73d181db273be8b306be6bc573dfe2257b
treec992cb283d9e60ba0e66dc9bc6f595878faa1873
parentb60e285b6acdec6d24fbde36d59f6d806f91cdc6
KVM: arm64: Properly save/restore HCRX_EL2

Rather than restoring HCRX_EL2 to a fixed value on vcpu exit,
perform a full save/restore of the register, ensuring that
we don't lose bits that would have been set at some point in
the host kernel lifetime, such as the GCSEn bit.

Fixes: ff5181d8a2a82 ("arm64/gcs: Provide basic EL2 setup to allow GCS usage at EL0 and EL1")
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20250430105916.3815157-2-maz@kernel.org
Signed-off-by: Oliver Upton <oliver.upton@linux.dev>
arch/arm64/kvm/hyp/include/hyp/switch.h