KVM: arm64: Replace vCPU target with a configuration flag
authorOliver Upton <oliver.upton@linux.dev>
Mon, 10 Jul 2023 19:31:39 +0000 (19:31 +0000)
committerMarc Zyngier <maz@kernel.org>
Tue, 11 Jul 2023 08:40:52 +0000 (09:40 +0100)
commitef98406036769107d5c49a519b31c940910b98d3
treeb915e88fac941c3df16d5ee3f802e2b9a4255e4a
parentc8a67729b8a36a5f4857de645ee9808fc99d8618
KVM: arm64: Replace vCPU target with a configuration flag

The value of kvm_vcpu_arch::target has been used to determine if a vCPU
has actually been initialized. Storing this as an integer is needless at
this point, as KVM doesn't do any microarch-specific emulation in the
first place. Instead, all we care about is whether or not the vCPU has
been initialized.

Delete the field in favor of a vCPU configuration flag indicating if
KVM_ARM_VCPU_INIT has completed for the vCPU.

Reviewed-by: Zenghui Yu <yuzenghui@huawei.com>
Signed-off-by: Oliver Upton <oliver.upton@linux.dev>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20230710193140.1706399-4-oliver.upton@linux.dev
arch/arm64/include/asm/kvm_host.h
arch/arm64/kvm/arm.c
arch/arm64/kvm/hyp/nvhe/switch.c