diff options
author | Haozhong Zhang <haozhong.zhang@intel.com> | 2015-11-24 11:33:57 +0800 |
---|---|---|
committer | Eduardo Habkost <ehabkost@redhat.com> | 2016-01-21 12:47:16 -0200 |
commit | 36f96c4b6bd25f43000c317518ff3df10202bc75 (patch) | |
tree | 9d06b5464aa50dfd100e69f20a61f47cb32e774d /hw/i386/pc_piix.c | |
parent | 5031283d5296dac8d410fa7b01fb6799ccfc76e9 (diff) | |
download | qemu-36f96c4b6bd25f43000c317518ff3df10202bc75.tar.gz qemu-36f96c4b6bd25f43000c317518ff3df10202bc75.tar.bz2 qemu-36f96c4b6bd25f43000c317518ff3df10202bc75.zip |
target-i386: Add support to migrate vcpu's TSC rate
This patch enables migrating vcpu's TSC rate. If KVM on the
destination machine supports TSC scaling, guest programs will
observe a consistent TSC rate across the migration.
If TSC scaling is not supported on the destination machine, the
migration will not be aborted and QEMU on the destination will
not set vcpu's TSC rate to the migrated value.
If vcpu's TSC rate specified by CPU option 'tsc-freq' on the
destination machine is inconsistent with the migrated TSC rate,
the migration will be aborted.
For backwards compatibility, the migration of vcpu's TSC rate is
disabled on pc-*-2.5 and older machine types.
Signed-off-by: Haozhong Zhang <haozhong.zhang@intel.com>
Reviewed-by: Eduardo Habkost <ehabkost@redhat.com>
[ehabkost: Rewrote comment at kvm_arch_put_registers()]
[ehabkost: Moved compat code to pc-2.5]
Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
Diffstat (limited to 'hw/i386/pc_piix.c')
-rw-r--r-- | hw/i386/pc_piix.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/hw/i386/pc_piix.c b/hw/i386/pc_piix.c index df2b824385..97219129ac 100644 --- a/hw/i386/pc_piix.c +++ b/hw/i386/pc_piix.c @@ -432,9 +432,11 @@ DEFINE_I440FX_MACHINE(v2_6, "pc-i440fx-2.6", NULL, static void pc_i440fx_2_5_machine_options(MachineClass *m) { + PCMachineClass *pcmc = PC_MACHINE_CLASS(m); pc_i440fx_2_6_machine_options(m); m->alias = NULL; m->is_default = 0; + pcmc->save_tsc_khz = false; SET_MACHINE_COMPAT(m, PC_COMPAT_2_5); } |