KVM: arm64: Add hyp_spinlock_t static initializer
authorFuad Tabba <tabba@google.com>
Thu, 10 Nov 2022 19:02:43 +0000 (19:02 +0000)
committerMarc Zyngier <maz@kernel.org>
Fri, 11 Nov 2022 16:40:54 +0000 (16:40 +0000)
commit1c80002e3264552d8b9c0e162e09aa4087403716
tree9eed618e07926be900b15b1c53cbc3e3b6ef4e3e
parent4d968b12e6bbe4440f4f220c41d779e02df8af1a
KVM: arm64: Add hyp_spinlock_t static initializer

Introduce a static initializer macro for 'hyp_spinlock_t' so that it is
straightforward to instantiate global locks at EL2. This will be later
utilised for locking the VM table in the hypervisor.

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Tested-by: Vincent Donnefort <vdonnefort@google.com>
Signed-off-by: Fuad Tabba <tabba@google.com>
Signed-off-by: Will Deacon <will@kernel.org>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Link: https://lore.kernel.org/r/20221110190259.26861-11-will@kernel.org
arch/arm64/kvm/hyp/include/nvhe/spinlock.h