On 4/25/2024 3:07 PM, Reinette Chatre wrote: > diff --git a/tools/testing/selftests/kvm/x86_64/apic_bus_clock_test.c b/tools/testing/selftests/kvm/x86_64/apic_bus_clock_test.c > new file mode 100644 > index 000000000000..5100b28228af > --- /dev/null > +++ b/tools/testing/selftests/kvm/x86_64/apic_bus_clock_test.c > @@ -0,0 +1,166 @@ > +// SPDX-License-Identifier: GPL-2.0-only > +/* > + * Test configure of APIC bus frequency. > + * > + * Copyright (c) 2024 Intel Corporation > + * > + * To verify if the APIC bus frequency can be configured this test starts Nit: some typos here? > +int main(int argc, char *argv[]) > +{ > + struct kvm_vcpu *vcpu; > + struct kvm_vm *vm; > + > + TEST_REQUIRE(kvm_has_cap(KVM_CAP_X86_APIC_BUS_CYCLES_NS)); > + > + vm = __vm_create(VM_SHAPE_DEFAULT, 1, 0); Use vm_create() instead?