i386/tdx: Disable pmu for TD guest
Current KVM doesn't support PMU for TD guest. It returns error if TD is created with PMU bit being set in attributes. Disable PMU for TD guest on QEMU side. Signed-off-by: Xiaoyao Li <xiaoyao.li@intel.com>
This commit is contained in:
@@ -496,6 +496,8 @@ int tdx_pre_create_vcpu(CPUState *cpu, Error **errp)
|
||||
g_autofree struct kvm_tdx_init_vm *init_vm = NULL;
|
||||
int r = 0;
|
||||
|
||||
object_property_set_bool(OBJECT(cpu), "pmu", false, &error_abort);
|
||||
|
||||
QEMU_LOCK_GUARD(&tdx_guest->lock);
|
||||
if (tdx_guest->initialized) {
|
||||
return r;
|
||||
|
||||
Reference in New Issue
Block a user