]> git.baikalelectronics.ru Git - kernel.git/commit
KVM: MTRR: introduce fixed_mtrr_addr_* functions
authorXiao Guangrong <guangrong.xiao@linux.intel.com>
Mon, 15 Jun 2015 08:55:32 +0000 (16:55 +0800)
committerPaolo Bonzini <pbonzini@redhat.com>
Fri, 19 Jun 2015 15:16:28 +0000 (17:16 +0200)
commitb65c06b0e76e7c67a9b1ded82061f8539e2c35dd
treea27ab306e80b1d48705a61335122f4aa30175324
parent09c7b8e3cc62d35b1b6d66b39d922c601cf46811
KVM: MTRR: introduce fixed_mtrr_addr_* functions

Two functions are introduced:
- fixed_mtrr_addr_to_seg() translates the address to the fixed
  MTRR segment

- fixed_mtrr_addr_seg_to_range_index() translates the address to
  the index of kvm_mtrr.fixed_ranges[]

They will be used in the later patch

Signed-off-by: Xiao Guangrong <guangrong.xiao@linux.intel.com>
[Adjust for range_size->range_shift change. - Paolo]
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
arch/x86/kvm/mtrr.c