static void set_cpuid_after_run(struct kvm_vcpu *vcpu)
{
- struct kvm_cpuid2 *cpuid = vcpu->cpuid;
struct kvm_cpuid_entry2 *ent;
int rc;
u32 eax, ebx, x;
TEST_ASSERT(!rc, "Setting unmodified CPUID after KVM_RUN failed: %d", rc);
/* Changing CPU features is forbidden */
- ent = get_cpuid_entry(cpuid, 0x7, 0);
+ ent = vcpu_get_cpuid_entry(vcpu, 0x7);
ebx = ent->ebx;
ent->ebx--;
rc = __vcpu_set_cpuid(vcpu);
ent->ebx = ebx;
/* Changing MAXPHYADDR is forbidden */
- ent = get_cpuid_entry(cpuid, 0x80000008, 0);
+ ent = vcpu_get_cpuid_entry(vcpu, 0x80000008);
eax = ent->eax;
x = eax & 0xff;
ent->eax = (eax & ~0xffu) | (x - 1);