]> www.infradead.org Git - users/jedix/linux-maple.git/commit
KVM: arm64: nv: Use guest hypervisor's max VL when running nested guest
authorOliver Upton <oliver.upton@linux.dev>
Thu, 20 Jun 2024 16:46:43 +0000 (16:46 +0000)
committerOliver Upton <oliver.upton@linux.dev>
Thu, 20 Jun 2024 19:02:40 +0000 (19:02 +0000)
commit9092aca9fe9aa986b573355affdd190710a906c0
tree0f422804d9b69c205edbb8f211b35fe6caf77bb6
parentb7e5c9426429aa64cacc2d804417e0e5f79b8b60
KVM: arm64: nv: Use guest hypervisor's max VL when running nested guest

The max VL for nested guests is additionally constrained by the max VL
selected by the guest hypervisor. Use that instead of KVM's max VL when
running a nested guest.

Note that the guest hypervisor's ZCR_EL2 is sanitised against the VM's
max VL at the time of access, so there's no additional handling required
at the time of use.

Reviewed-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20240620164653.1130714-7-oliver.upton@linux.dev
Signed-off-by: Oliver Upton <oliver.upton@linux.dev>
arch/arm64/kvm/hyp/include/hyp/switch.h