aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc
diff options
context:
space:
mode:
authorXiao Guangrong <xiaoguangrong.eric@gmail.com>2011-11-24 06:04:35 -0500
committerAvi Kivity <avi@redhat.com>2011-12-27 04:17:39 -0500
commit28a37544fb0223eb9805d2567b88f7360edec52a (patch)
tree83afb64f8448303f9486eb6c87980695611275ab /arch/powerpc
parentbe6ba0f0962a39091c52eb9167ddea201fe80716 (diff)
KVM: introduce id_to_memslot function
Introduce id_to_memslot to get memslot by slot id Signed-off-by: Xiao Guangrong <xiaoguangrong@linux.vnet.ibm.com> Signed-off-by: Avi Kivity <avi@redhat.com>
Diffstat (limited to 'arch/powerpc')
-rw-r--r--arch/powerpc/kvm/book3s.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/powerpc/kvm/book3s.c b/arch/powerpc/kvm/book3s.c
index a459479995c6..e41ac6f7dcf1 100644
--- a/arch/powerpc/kvm/book3s.c
+++ b/arch/powerpc/kvm/book3s.c
@@ -498,7 +498,7 @@ int kvm_vm_ioctl_get_dirty_log(struct kvm *kvm,
498 498
499 /* If nothing is dirty, don't bother messing with page tables. */ 499 /* If nothing is dirty, don't bother messing with page tables. */
500 if (is_dirty) { 500 if (is_dirty) {
501 memslot = &kvm->memslots->memslots[log->slot]; 501 memslot = id_to_memslot(kvm->memslots, log->slot);
502 502
503 ga = memslot->base_gfn << PAGE_SHIFT; 503 ga = memslot->base_gfn << PAGE_SHIFT;
504 ga_end = ga + (memslot->npages << PAGE_SHIFT); 504 ga_end = ga + (memslot->npages << PAGE_SHIFT);