kvm: qemu: separate TSC load from kvm_arch_load_regs
commitf937ff7296edb04cd49e3aa888d164332e5b33b9
authorMarcelo Tosatti <mtosatti@redhat.com>
Tue, 9 Dec 2008 01:12:48 +0000 (8 23:12 -0200)
committerAvi Kivity <avi@redhat.com>
Sun, 28 Dec 2008 09:31:51 +0000 (28 11:31 +0200)
tree15987332a46ec809beadc6c5f3b87dcc3e4a641c
parent229edb21a53348bc260bb23ed50dce0c4fb447a6
kvm: qemu: separate TSC load from kvm_arch_load_regs

kvm_load_registers is a general interface to load registers, and is
used by vmport, gdbstub, etc. The TSC MSR is continually counting, so
it can't be simply read and written back as the other registers/MSR's
(doing so overwrites the current count).

Introduce kvm_load_tsc and use it for x86's migration CPU load code.

Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
Signed-off-by: Avi Kivity <avi@redhat.com>
qemu/qemu-kvm-x86.c
qemu/qemu-kvm.h
qemu/target-i386/machine.c