aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc/kvm
diff options
context:
space:
mode:
authorAlexander Graf <agraf@suse.de>2010-07-29 08:47:52 -0400
committerAvi Kivity <avi@redhat.com>2010-10-24 04:50:46 -0400
commit28e83b4fa7f8bd114940fa933ac8cbe80969eba2 (patch)
treeae4daee5d2977bb2aa0ea2e07d7640895a874fb5 /arch/powerpc/kvm
parent90bba358873dc96a6746f0df453a0a8ca3d6b86e (diff)
KVM: PPC: Make PAM a define
On PowerPC it's very normal to not support all of the physical RAM in real mode. To check if we're matching on the shared page or not, we need to know the limits so we can restrain ourselves to that range. So let's make it a define instead of open-coding it. And while at it, let's also increase it. Signed-off-by: Alexander Graf <agraf@suse.de> v2 -> v3: - RMO -> PAM (non-magic page) Signed-off-by: Avi Kivity <avi@redhat.com>
Diffstat (limited to 'arch/powerpc/kvm')
-rw-r--r--arch/powerpc/kvm/book3s.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/powerpc/kvm/book3s.c b/arch/powerpc/kvm/book3s.c
index 06229fec5c9f..0ed5376df82c 100644
--- a/arch/powerpc/kvm/book3s.c
+++ b/arch/powerpc/kvm/book3s.c
@@ -465,7 +465,7 @@ static int kvmppc_xlate(struct kvm_vcpu *vcpu, ulong eaddr, bool data,
465 r = vcpu->arch.mmu.xlate(vcpu, eaddr, pte, data); 465 r = vcpu->arch.mmu.xlate(vcpu, eaddr, pte, data);
466 } else { 466 } else {
467 pte->eaddr = eaddr; 467 pte->eaddr = eaddr;
468 pte->raddr = eaddr & 0xffffffff; 468 pte->raddr = eaddr & KVM_PAM;
469 pte->vpage = VSID_REAL | eaddr >> 12; 469 pte->vpage = VSID_REAL | eaddr >> 12;
470 pte->may_read = true; 470 pte->may_read = true;
471 pte->may_write = true; 471 pte->may_write = true;
@@ -579,7 +579,7 @@ int kvmppc_handle_pagefault(struct kvm_run *run, struct kvm_vcpu *vcpu,
579 pte.may_execute = true; 579 pte.may_execute = true;
580 pte.may_read = true; 580 pte.may_read = true;
581 pte.may_write = true; 581 pte.may_write = true;
582 pte.raddr = eaddr & 0xffffffff; 582 pte.raddr = eaddr & KVM_PAM;
583 pte.eaddr = eaddr; 583 pte.eaddr = eaddr;
584 pte.vpage = eaddr >> 12; 584 pte.vpage = eaddr >> 12;
585 } 585 }