KVM: arm64: Initialize the kvm host data's fpsimd_state pointer in pKVM
authorFuad Tabba <tabba@google.com>
Tue, 23 Apr 2024 15:05:09 +0000 (16:05 +0100)
committerMarc Zyngier <maz@kernel.org>
Wed, 1 May 2024 15:46:58 +0000 (16:46 +0100)
commit4c22a40dd9c3dcc2156f312ffc71955e56192a76
treed6945eed107a84653b4cbc0d7f46ecdf2d36768d
parent5294afdbf45aced5295fe5941c58b40c41c23800
KVM: arm64: Initialize the kvm host data's fpsimd_state pointer in pKVM

Since the host_fpsimd_state has been removed from kvm_vcpu_arch,
it isn't pointing to the hyp's version of the host fp_regs in
protected mode.

Initialize the host_data fpsimd_state point to the host_data's
context fp_regs on pKVM initialization.

Fixes: 51e09b5572d6 ("KVM: arm64: Exclude host_fpsimd_state pointer from kvm_vcpu_arch")
Signed-off-by: Fuad Tabba <tabba@google.com>
Acked-by: Oliver Upton <oliver.upton@linux.dev>
Link: https://lore.kernel.org/r/20240423150538.2103045-2-tabba@google.com
Signed-off-by: Marc Zyngier <maz@kernel.org>
arch/arm64/kvm/hyp/include/nvhe/pkvm.h
arch/arm64/kvm/hyp/nvhe/pkvm.c
arch/arm64/kvm/hyp/nvhe/setup.c