aboutsummaryrefslogtreecommitdiffstats
path: root/tools/testing/selftests/kvm/include
diff options
context:
space:
mode:
authorOliver Upton <oliver.upton@linux.dev>2025-09-17 14:20:33 -0700
committerMarc Zyngier <maz@kernel.org>2025-09-24 19:23:32 +0100
commitb712afa7a1cdb787f311f51c04df81fc6f026368 (patch)
tree6e3b9688e7a2effd9d4cb57914c7fa151bc774f5 /tools/testing/selftests/kvm/include
parentKVM: arm64: selftests: Initialize VGICv3 only once (diff)
downloadlinux-b712afa7a1cdb787f311f51c04df81fc6f026368.tar.gz
linux-b712afa7a1cdb787f311f51c04df81fc6f026368.zip
KVM: arm64: selftests: Add helper to check for VGICv3 support
Introduce a proper predicate for probing VGICv3 by performing a 'test' creation of the device on a dummy VM. Signed-off-by: Oliver Upton <oliver.upton@linux.dev> Signed-off-by: Marc Zyngier <maz@kernel.org>
Diffstat (limited to 'tools/testing/selftests/kvm/include')
-rw-r--r--tools/testing/selftests/kvm/include/arm64/vgic.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/tools/testing/selftests/kvm/include/arm64/vgic.h b/tools/testing/selftests/kvm/include/arm64/vgic.h
index c481d0c00a5d..b858fa8195b4 100644
--- a/tools/testing/selftests/kvm/include/arm64/vgic.h
+++ b/tools/testing/selftests/kvm/include/arm64/vgic.h
@@ -16,6 +16,7 @@
((uint64_t)(flags) << 12) | \
index)
+bool kvm_supports_vgic_v3(void);
int vgic_v3_setup(struct kvm_vm *vm, unsigned int nr_vcpus, uint32_t nr_irqs);
#define VGIC_MAX_RESERVED 1023