summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAvi Kivity <avi@redhat.com>2009-11-22 15:01:01 +0200
committerAvi Kivity <avi@redhat.com>2009-11-22 15:01:01 +0200
commitbf0720cc18479a69fa41789b5a2691376b6809d3 (patch)
tree2e16f79a9e006d45e5f0e8a2fedf441b65834dd3 /target-i386
parentMerge commit 'f527c57935e22b56952d1ed1af36070b682ecf70' into upstream-merge (diff)
parentpci: Fix function pci_default_write_config (diff)
downloadqemu-kvm-bf0720cc18479a69fa41789b5a2691376b6809d3.tar.gz
qemu-kvm-bf0720cc18479a69fa41789b5a2691376b6809d3.tar.bz2
qemu-kvm-bf0720cc18479a69fa41789b5a2691376b6809d3.zip
Merge commit '91011d4f3b7c311a42b842f6682ac64a2372d2b7' into upstream-merge
* commit '91011d4f3b7c311a42b842f6682ac64a2372d2b7': pci: Fix function pci_default_write_config mips: fix CPU reset Fix PPC crash ARM MPCore tweaks Realview/EB procid hacks pci: fix the conversion of config field from array to pointer qemu_system_reset: we need to call it before loadvm/migration fdc: fix vmstate variable passed vnc: improve capslock handling. e1000 fix: read access to some registers is missing. Fix 32-bit overflow in parallels image support kvm ppc: Remove unused label kvm: Move KVM mp_state accessors to i386-specific code virtio-blk: Pass read errors to the guest savevm: Delete existing snapshots in all images Fix incoming migration fix type in CFLAGS name Conflicts: hw/pci.c Signed-off-by: Avi Kivity <avi@redhat.com>
Diffstat (limited to 'target-i386')
-rw-r--r--target-i386/kvm.c20
1 files changed, 20 insertions, 0 deletions
diff --git a/target-i386/kvm.c b/target-i386/kvm.c
index 24c990367..83c83297b 100644
--- a/target-i386/kvm.c
+++ b/target-i386/kvm.c
@@ -665,6 +665,26 @@ static int kvm_get_msrs(CPUState *env)
return 0;
}
+static int kvm_put_mp_state(CPUState *env)
+{
+ struct kvm_mp_state mp_state = { .mp_state = env->mp_state };
+
+ return kvm_vcpu_ioctl(env, KVM_SET_MP_STATE, &mp_state);
+}
+
+static int kvm_get_mp_state(CPUState *env)
+{
+ struct kvm_mp_state mp_state;
+ int ret;
+
+ ret = kvm_vcpu_ioctl(env, KVM_GET_MP_STATE, &mp_state);
+ if (ret < 0) {
+ return ret;
+ }
+ env->mp_state = mp_state.mp_state;
+ return 0;
+}
+
int kvm_arch_put_registers(CPUState *env)
{
int ret;