]> www.infradead.org Git - users/jedix/linux-maple.git/commit
KVM: arm64: Make L1Ip feature in CTR_EL0 writable from userspace
authorShameer Kolothum <shameerali.kolothum.thodi@huawei.com>
Tue, 22 Oct 2024 07:39:43 +0000 (08:39 +0100)
committerOliver Upton <oliver.upton@linux.dev>
Mon, 11 Nov 2024 18:33:09 +0000 (18:33 +0000)
commite9b57d7f9740deb31acb02a00bdf6653e60c7e61
tree1585c3817184797c26d50e5782b3ab98e9e381a9
parent75cd027cbcb161e277209e20df14f0818c62d9e7
KVM: arm64: Make L1Ip feature in CTR_EL0 writable from userspace

Only allow userspace to set VIPT(0b10) or PIPT(0b11) for L1Ip based on
what hardware reports as both AIVIVT (0b01) and VPIPT (0b00) are
documented as reserved.

Using a VIPT for Guest where hardware reports PIPT may lead to over
invalidation, but is still correct. Hence, we can allow downgrading
PIPT to VIPT, but not the other way around.

Reviewed-by: Sebastian Ott <sebott@redhat.com>
Reviewed-by: Marc Zyngier <maz@kernel.org>
Signed-off-by: Shameer Kolothum <shameerali.kolothum.thodi@huawei.com>
Link: https://lore.kernel.org/r/20241022073943.35764-1-shameerali.kolothum.thodi@huawei.com
Signed-off-by: Oliver Upton <oliver.upton@linux.dev>
arch/arm64/kvm/sys_regs.c