diff options
author | Xiao Guangrong <guangrong.xiao@linux.intel.com> | 2015-06-15 16:55:31 +0800 |
---|---|---|
committer | Paolo Bonzini <pbonzini@redhat.com> | 2015-06-19 17:16:28 +0200 |
commit | 19efffa244071ccd0385b240d03adb38feaab04e (patch) | |
tree | d6fce4bc6222d5ae0be4d42099b516e9ce70a96e /arch/x86/kvm/x86.c | |
parent | a13842dc668b40daef4327294a6d3bdc8bd30276 (diff) | |
download | lwn-19efffa244071ccd0385b240d03adb38feaab04e.tar.gz lwn-19efffa244071ccd0385b240d03adb38feaab04e.zip |
KVM: MTRR: sort variable MTRRs
Sort all valid variable MTRRs based on its base address, it will help us to
check a range to see if it's fully contained in variable MTRRs
Signed-off-by: Xiao Guangrong <guangrong.xiao@linux.intel.com>
[Fix list insertion sort, simplify var_mtrr_range_is_valid to just
test the V bit. - Paolo]
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Diffstat (limited to 'arch/x86/kvm/x86.c')
-rw-r--r-- | arch/x86/kvm/x86.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/x86/kvm/x86.c b/arch/x86/kvm/x86.c index 2ffad7f2a28e..6574fa36cb65 100644 --- a/arch/x86/kvm/x86.c +++ b/arch/x86/kvm/x86.c @@ -7379,13 +7379,13 @@ int kvm_arch_vcpu_setup(struct kvm_vcpu *vcpu) { int r; + kvm_vcpu_mtrr_init(vcpu); r = vcpu_load(vcpu); if (r) return r; kvm_vcpu_reset(vcpu, false); kvm_mmu_setup(vcpu); vcpu_put(vcpu); - return r; } |