aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc/kvm/book3s.c
diff options
context:
space:
mode:
authorAlexander Graf <agraf@suse.de>2010-06-30 09:18:46 -0400
committerAvi Kivity <avi@redhat.com>2010-08-01 03:47:28 -0400
commitfef093bec0364ff5e6fd488cd81637f6bb3a2d0d (patch)
treee61c2f462a5b68d440d3960af41e3f17ea7f765f /arch/powerpc/kvm/book3s.c
parent7741909bf19d9437a6aa3559c0470a640f637dce (diff)
KVM: PPC: Make use of hash based Shadow MMU
We just introduced generic functions to handle shadow pages on PPC. This patch makes the respective backends make use of them, getting rid of a lot of duplicate code along the way. Signed-off-by: Alexander Graf <agraf@suse.de> Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
Diffstat (limited to 'arch/powerpc/kvm/book3s.c')
-rw-r--r--arch/powerpc/kvm/book3s.c14
1 files changed, 12 insertions, 2 deletions
diff --git a/arch/powerpc/kvm/book3s.c b/arch/powerpc/kvm/book3s.c
index 801d9f3c70ae..a3cef30d1d42 100644
--- a/arch/powerpc/kvm/book3s.c
+++ b/arch/powerpc/kvm/book3s.c
@@ -1384,12 +1384,22 @@ int __kvmppc_vcpu_run(struct kvm_run *kvm_run, struct kvm_vcpu *vcpu)
1384 1384
1385static int kvmppc_book3s_init(void) 1385static int kvmppc_book3s_init(void)
1386{ 1386{
1387 return kvm_init(NULL, sizeof(struct kvmppc_vcpu_book3s), 0, 1387 int r;
1388 THIS_MODULE); 1388
1389 r = kvm_init(NULL, sizeof(struct kvmppc_vcpu_book3s), 0,
1390 THIS_MODULE);
1391
1392 if (r)
1393 return r;
1394
1395 r = kvmppc_mmu_hpte_sysinit();
1396
1397 return r;
1389} 1398}
1390 1399
1391static void kvmppc_book3s_exit(void) 1400static void kvmppc_book3s_exit(void)
1392{ 1401{
1402 kvmppc_mmu_hpte_sysexit();
1393 kvm_exit(); 1403 kvm_exit();
1394} 1404}
1395 1405