]> git.baikalelectronics.ru Git - kernel.git/commitdiff
KVM: x86: remove data variable from kvm_get_msr_common
authorNicolas Iooss <nicolas.iooss_linux@m4x.org>
Mon, 29 Jun 2015 10:39:23 +0000 (18:39 +0800)
committerPaolo Bonzini <pbonzini@redhat.com>
Fri, 3 Jul 2015 16:55:19 +0000 (18:55 +0200)
Commit 858838b5db46 ("KVM: x86: pass host_initiated to functions that
read MSRs") modified kvm_get_msr_common function to use msr_info->data
instead of data but missed one occurrence.  Replace it and remove the
unused local variable.

Fixes: 858838b5db46 ("KVM: x86: pass host_initiated to functions that
read MSRs")
Signed-off-by: Nicolas Iooss <nicolas.iooss_linux@m4x.org>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
arch/x86/kvm/x86.c

index ac165c2fb8e54a307cb3f70a5e990635f95978b2..bbaf44e8f0d3cdd7100c40c98ccf2ab40ae1ea2f 100644 (file)
@@ -2379,8 +2379,6 @@ static int get_msr_hyperv(struct kvm_vcpu *vcpu, u32 msr, u64 *pdata)
 
 int kvm_get_msr_common(struct kvm_vcpu *vcpu, struct msr_data *msr_info)
 {
-       u64 data;
-
        switch (msr_info->index) {
        case MSR_IA32_PLATFORM_ID:
        case MSR_IA32_EBL_CR_POWERON:
@@ -2453,7 +2451,7 @@ int kvm_get_msr_common(struct kvm_vcpu *vcpu, struct msr_data *msr_info)
                /* TSC increment by tick */
                msr_info->data = 1000ULL;
                /* CPU multiplier */
-               data |= (((uint64_t)4ULL) << 40);
+               msr_info->data |= (((uint64_t)4ULL) << 40);
                break;
        case MSR_EFER:
                msr_info->data = vcpu->arch.efer;