aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoraurel32 <aurel32@c046a42c-6fe2-441c-8c8c-71466251a162>2008-12-16 10:43:58 +0000
committeraurel32 <aurel32@c046a42c-6fe2-441c-8c8c-71466251a162>2008-12-16 10:43:58 +0000
commitd76d16501ef27fdf3ac8c1f9b7cf59b59a661ec3 (patch)
tree7ac820762695e1cb0022bc000c50b9c2f2172bae /target-ppc/helper.c
parentImplement device tree support needed for Bamboo emulation (diff)
downloadqemu-kvm-d76d16501ef27fdf3ac8c1f9b7cf59b59a661ec3.tar.gz
qemu-kvm-d76d16501ef27fdf3ac8c1f9b7cf59b59a661ec3.tar.bz2
qemu-kvm-d76d16501ef27fdf3ac8c1f9b7cf59b59a661ec3.zip
target-ppc: Enable KVM for ppcemb.
Implement hooks called by generic KVM code. Also add code that will copy the host's CPU and timebase frequencies to the guest, which is necessary on KVM because the guest can directly access the timebase. Signed-off-by: Hollis Blanchard <hollisb@us.ibm.com> Acked-by: Anthony Liguori <aliguori@us.ibm.com> Signed-off-by: Aurelien Jarno <aurelien@aurel32.net> git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@6065 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'target-ppc/helper.c')
-rw-r--r--target-ppc/helper.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/target-ppc/helper.c b/target-ppc/helper.c
index 538d9f34c..4676d50d8 100644
--- a/target-ppc/helper.c
+++ b/target-ppc/helper.c
@@ -29,6 +29,7 @@
#include "exec-all.h"
#include "helper_regs.h"
#include "qemu-common.h"
+#include "kvm.h"
//#define DEBUG_MMU
//#define DEBUG_BATS
@@ -2920,6 +2921,10 @@ CPUPPCState *cpu_ppc_init (const char *cpu_model)
env->cpu_model_str = cpu_model;
cpu_ppc_register_internal(env, def);
cpu_ppc_reset(env);
+
+ if (kvm_enabled())
+ kvm_init_vcpu(env);
+
return env;
}