Message ID | 1332345997-4772-1-git-send-email-vianac@linux.vnet.ibm.com |
---|---|
State | New |
Headers | show |
Il 21/03/2012 17:06, Crístian Viana ha scritto: > The current value for the -rtc timedrift option is none. This patch > makes sure that the old machines configuration will work the same way > even after that option changes its default value. > > Signed-off-by: Crístian Viana <vianac@linux.vnet.ibm.com> > --- > hw/pc_piix.c | 39 +++++++++++++++++++++++++++++++++++++++ > 1 files changed, 39 insertions(+), 0 deletions(-) > > diff --git a/hw/pc_piix.c b/hw/pc_piix.c > index 3f99f9a..08255b5 100644 > --- a/hw/pc_piix.c > +++ b/hw/pc_piix.c > @@ -386,6 +386,10 @@ static QEMUMachine pc_machine_v1_0 = { > .driver = "isa-fdc", > .property = "check_media_rate", > .value = "off", > + }, { > + .driver = "mc146818rtc", > + .property = "lost_tick_policy", > + .value = "none", > }, > { /* end of list */ } > }, > @@ -405,6 +409,10 @@ static QEMUMachine pc_machine_v0_15 = { > .driver = "isa-fdc", > .property = "check_media_rate", > .value = "off", > + }, { > + .driver = "mc146818rtc", > + .property = "lost_tick_policy", > + .value = "none", > }, > { /* end of list */ } > }, > @@ -449,6 +457,10 @@ static QEMUMachine pc_machine_v0_14 = { > .driver = "pc-sysfw", > .property = "rom_only", > .value = stringify(1), > + }, { > + .driver = "mc146818rtc", > + .property = "lost_tick_policy", > + .value = "none", > }, > { /* end of list */ } > }, > @@ -505,6 +517,10 @@ static QEMUMachine pc_machine_v0_13 = { > .driver = "pc-sysfw", > .property = "rom_only", > .value = stringify(1), > + }, { > + .driver = "mc146818rtc", > + .property = "lost_tick_policy", > + .value = "none", > }, > { /* end of list */ } > }, > @@ -565,6 +581,10 @@ static QEMUMachine pc_machine_v0_12 = { > .driver = "pc-sysfw", > .property = "rom_only", > .value = stringify(1), > + }, { > + .driver = "mc146818rtc", > + .property = "lost_tick_policy", > + .value = "none", > }, > { /* end of list */ } > } > @@ -633,6 +653,10 @@ static QEMUMachine pc_machine_v0_11 = { > .driver = "pc-sysfw", > .property = "rom_only", > .value = stringify(1), > + }, { > + .driver = "mc146818rtc", > + .property = "lost_tick_policy", > + .value = "none", > }, > { /* end of list */ } > } > @@ -713,6 +737,10 @@ static QEMUMachine pc_machine_v0_10 = { > .driver = "pc-sysfw", > .property = "rom_only", > .value = stringify(1), > + }, { > + .driver = "mc146818rtc", > + .property = "lost_tick_policy", > + .value = "none", > }, > { /* end of list */ } > }, > @@ -728,6 +756,10 @@ static QEMUMachine isapc_machine = { > .driver = "pc-sysfw", > .property = "rom_only", > .value = stringify(1), > + }, { > + .driver = "mc146818rtc", > + .property = "lost_tick_policy", > + .value = "none", > }, > { /* end of list */ } > }, > @@ -740,6 +772,13 @@ static QEMUMachine xenfv_machine = { > .init = pc_xen_hvm_init, > .max_cpus = HVM_MAX_VCPUS, > .default_machine_opts = "accel=xen", > + .compat_props = (GlobalProperty[]) { > + { > + .driver = "mc146818rtc", > + .property = "lost_tick_policy", > + .value = "none", > + }, > + { /* end of list */ } > }; > #endif > Stefano, what do you want for Xen? Anyhow, Reviewed-by: Paolo Bonzini <pbonzini@redhat.com> Paolo
On Wed, 21 Mar 2012, Paolo Bonzini wrote: > Il 21/03/2012 17:06, Crístian Viana ha scritto: > > The current value for the -rtc timedrift option is none. This patch > > makes sure that the old machines configuration will work the same way > > even after that option changes its default value. > > > > Signed-off-by: Crístian Viana <vianac@linux.vnet.ibm.com> > > --- > > hw/pc_piix.c | 39 +++++++++++++++++++++++++++++++++++++++ > > 1 files changed, 39 insertions(+), 0 deletions(-) > > > > diff --git a/hw/pc_piix.c b/hw/pc_piix.c > > index 3f99f9a..08255b5 100644 > > --- a/hw/pc_piix.c > > +++ b/hw/pc_piix.c > > @@ -386,6 +386,10 @@ static QEMUMachine pc_machine_v1_0 = { > > .driver = "isa-fdc", > > .property = "check_media_rate", > > .value = "off", > > + }, { > > + .driver = "mc146818rtc", > > + .property = "lost_tick_policy", > > + .value = "none", > > }, > > { /* end of list */ } > > }, > > @@ -405,6 +409,10 @@ static QEMUMachine pc_machine_v0_15 = { > > .driver = "isa-fdc", > > .property = "check_media_rate", > > .value = "off", > > + }, { > > + .driver = "mc146818rtc", > > + .property = "lost_tick_policy", > > + .value = "none", > > }, > > { /* end of list */ } > > }, > > @@ -449,6 +457,10 @@ static QEMUMachine pc_machine_v0_14 = { > > .driver = "pc-sysfw", > > .property = "rom_only", > > .value = stringify(1), > > + }, { > > + .driver = "mc146818rtc", > > + .property = "lost_tick_policy", > > + .value = "none", > > }, > > { /* end of list */ } > > }, > > @@ -505,6 +517,10 @@ static QEMUMachine pc_machine_v0_13 = { > > .driver = "pc-sysfw", > > .property = "rom_only", > > .value = stringify(1), > > + }, { > > + .driver = "mc146818rtc", > > + .property = "lost_tick_policy", > > + .value = "none", > > }, > > { /* end of list */ } > > }, > > @@ -565,6 +581,10 @@ static QEMUMachine pc_machine_v0_12 = { > > .driver = "pc-sysfw", > > .property = "rom_only", > > .value = stringify(1), > > + }, { > > + .driver = "mc146818rtc", > > + .property = "lost_tick_policy", > > + .value = "none", > > }, > > { /* end of list */ } > > } > > @@ -633,6 +653,10 @@ static QEMUMachine pc_machine_v0_11 = { > > .driver = "pc-sysfw", > > .property = "rom_only", > > .value = stringify(1), > > + }, { > > + .driver = "mc146818rtc", > > + .property = "lost_tick_policy", > > + .value = "none", > > }, > > { /* end of list */ } > > } > > @@ -713,6 +737,10 @@ static QEMUMachine pc_machine_v0_10 = { > > .driver = "pc-sysfw", > > .property = "rom_only", > > .value = stringify(1), > > + }, { > > + .driver = "mc146818rtc", > > + .property = "lost_tick_policy", > > + .value = "none", > > }, > > { /* end of list */ } > > }, > > @@ -728,6 +756,10 @@ static QEMUMachine isapc_machine = { > > .driver = "pc-sysfw", > > .property = "rom_only", > > .value = stringify(1), > > + }, { > > + .driver = "mc146818rtc", > > + .property = "lost_tick_policy", > > + .value = "none", > > }, > > { /* end of list */ } > > }, > > @@ -740,6 +772,13 @@ static QEMUMachine xenfv_machine = { > > .init = pc_xen_hvm_init, > > .max_cpus = HVM_MAX_VCPUS, > > .default_machine_opts = "accel=xen", > > + .compat_props = (GlobalProperty[]) { > > + { > > + .driver = "mc146818rtc", > > + .property = "lost_tick_policy", > > + .value = "none", > > + }, > > + { /* end of list */ } > > }; > > #endif > > > > Stefano, what do you want for Xen? Anyhow, I would like to keep the old policy for Xen, so the patch is fine by me. Thanks for pinging me!
On 03/22/2012 05:37 AM, Stefano Stabellini wrote: > On Wed, 21 Mar 2012, Paolo Bonzini wrote: >> Il 21/03/2012 17:06, Crístian Viana ha scritto: >>> @@ -740,6 +772,13 @@ static QEMUMachine xenfv_machine = { >>> .init = pc_xen_hvm_init, >>> .max_cpus = HVM_MAX_VCPUS, >>> .default_machine_opts = "accel=xen", >>> + .compat_props = (GlobalProperty[]) { >>> + { >>> + .driver = "mc146818rtc", >>> + .property = "lost_tick_policy", >>> + .value = "none", >>> + }, >>> + { /* end of list */ } >>> }; >>> #endif >>> >> >> Stefano, what do you want for Xen? Anyhow, > > I would like to keep the old policy for Xen, so the patch is fine by me. > Thanks for pinging me! Xen emulates the RTC in the hypervisor, no? So it really wouldn't matter IIUC. Regards, Anthony Liguori
On 03/21/2012 11:06 AM, Crístian Viana wrote: > The current value for the -rtc timedrift option is none. This patch > makes sure that the old machines configuration will work the same way > even after that option changes its default value. > > Signed-off-by: Crístian Viana<vianac@linux.vnet.ibm.com> Something's off here: Using machine: pc-0.14 /home/anthony/build/qemu/x86_64-softmmu/qemu-system-x86_64 -kernel bin/vmlinuz-3.0 -initrd .tmp-22118/initramfs-22118.img.gz -append console=ttyS0 seed=64521 -nographic -enable-kvm -hda .tmp-22118/disk-22118.img -M pc-0.14 -drive file=.tmp-22118/disk-22118.img,if=virtio,snapshot=on -device virtio-balloon-pci -device virtio-serial -net nic,model=virtio -net user -pidfile .tmp-22118/pidfile-22118.pid -qmp unix:.tmp-22118/qmpsock-22118.sock,server,nowait qemu-system-x86_64: Invalid parameter 'lost_tick_policy' Regards, Anthony Liguori > --- > hw/pc_piix.c | 39 +++++++++++++++++++++++++++++++++++++++ > 1 files changed, 39 insertions(+), 0 deletions(-) > > diff --git a/hw/pc_piix.c b/hw/pc_piix.c > index 3f99f9a..08255b5 100644 > --- a/hw/pc_piix.c > +++ b/hw/pc_piix.c > @@ -386,6 +386,10 @@ static QEMUMachine pc_machine_v1_0 = { > .driver = "isa-fdc", > .property = "check_media_rate", > .value = "off", > + }, { > + .driver = "mc146818rtc", > + .property = "lost_tick_policy", > + .value = "none", > }, > { /* end of list */ } > }, > @@ -405,6 +409,10 @@ static QEMUMachine pc_machine_v0_15 = { > .driver = "isa-fdc", > .property = "check_media_rate", > .value = "off", > + }, { > + .driver = "mc146818rtc", > + .property = "lost_tick_policy", > + .value = "none", > }, > { /* end of list */ } > }, > @@ -449,6 +457,10 @@ static QEMUMachine pc_machine_v0_14 = { > .driver = "pc-sysfw", > .property = "rom_only", > .value = stringify(1), > + }, { > + .driver = "mc146818rtc", > + .property = "lost_tick_policy", > + .value = "none", > }, > { /* end of list */ } > }, > @@ -505,6 +517,10 @@ static QEMUMachine pc_machine_v0_13 = { > .driver = "pc-sysfw", > .property = "rom_only", > .value = stringify(1), > + }, { > + .driver = "mc146818rtc", > + .property = "lost_tick_policy", > + .value = "none", > }, > { /* end of list */ } > }, > @@ -565,6 +581,10 @@ static QEMUMachine pc_machine_v0_12 = { > .driver = "pc-sysfw", > .property = "rom_only", > .value = stringify(1), > + }, { > + .driver = "mc146818rtc", > + .property = "lost_tick_policy", > + .value = "none", > }, > { /* end of list */ } > } > @@ -633,6 +653,10 @@ static QEMUMachine pc_machine_v0_11 = { > .driver = "pc-sysfw", > .property = "rom_only", > .value = stringify(1), > + }, { > + .driver = "mc146818rtc", > + .property = "lost_tick_policy", > + .value = "none", > }, > { /* end of list */ } > } > @@ -713,6 +737,10 @@ static QEMUMachine pc_machine_v0_10 = { > .driver = "pc-sysfw", > .property = "rom_only", > .value = stringify(1), > + }, { > + .driver = "mc146818rtc", > + .property = "lost_tick_policy", > + .value = "none", > }, > { /* end of list */ } > }, > @@ -728,6 +756,10 @@ static QEMUMachine isapc_machine = { > .driver = "pc-sysfw", > .property = "rom_only", > .value = stringify(1), > + }, { > + .driver = "mc146818rtc", > + .property = "lost_tick_policy", > + .value = "none", > }, > { /* end of list */ } > }, > @@ -740,6 +772,13 @@ static QEMUMachine xenfv_machine = { > .init = pc_xen_hvm_init, > .max_cpus = HVM_MAX_VCPUS, > .default_machine_opts = "accel=xen", > + .compat_props = (GlobalProperty[]) { > + { > + .driver = "mc146818rtc", > + .property = "lost_tick_policy", > + .value = "none", > + }, > + { /* end of list */ } > }; > #endif >
diff --git a/hw/pc_piix.c b/hw/pc_piix.c index 3f99f9a..08255b5 100644 --- a/hw/pc_piix.c +++ b/hw/pc_piix.c @@ -386,6 +386,10 @@ static QEMUMachine pc_machine_v1_0 = { .driver = "isa-fdc", .property = "check_media_rate", .value = "off", + }, { + .driver = "mc146818rtc", + .property = "lost_tick_policy", + .value = "none", }, { /* end of list */ } }, @@ -405,6 +409,10 @@ static QEMUMachine pc_machine_v0_15 = { .driver = "isa-fdc", .property = "check_media_rate", .value = "off", + }, { + .driver = "mc146818rtc", + .property = "lost_tick_policy", + .value = "none", }, { /* end of list */ } }, @@ -449,6 +457,10 @@ static QEMUMachine pc_machine_v0_14 = { .driver = "pc-sysfw", .property = "rom_only", .value = stringify(1), + }, { + .driver = "mc146818rtc", + .property = "lost_tick_policy", + .value = "none", }, { /* end of list */ } }, @@ -505,6 +517,10 @@ static QEMUMachine pc_machine_v0_13 = { .driver = "pc-sysfw", .property = "rom_only", .value = stringify(1), + }, { + .driver = "mc146818rtc", + .property = "lost_tick_policy", + .value = "none", }, { /* end of list */ } }, @@ -565,6 +581,10 @@ static QEMUMachine pc_machine_v0_12 = { .driver = "pc-sysfw", .property = "rom_only", .value = stringify(1), + }, { + .driver = "mc146818rtc", + .property = "lost_tick_policy", + .value = "none", }, { /* end of list */ } } @@ -633,6 +653,10 @@ static QEMUMachine pc_machine_v0_11 = { .driver = "pc-sysfw", .property = "rom_only", .value = stringify(1), + }, { + .driver = "mc146818rtc", + .property = "lost_tick_policy", + .value = "none", }, { /* end of list */ } } @@ -713,6 +737,10 @@ static QEMUMachine pc_machine_v0_10 = { .driver = "pc-sysfw", .property = "rom_only", .value = stringify(1), + }, { + .driver = "mc146818rtc", + .property = "lost_tick_policy", + .value = "none", }, { /* end of list */ } }, @@ -728,6 +756,10 @@ static QEMUMachine isapc_machine = { .driver = "pc-sysfw", .property = "rom_only", .value = stringify(1), + }, { + .driver = "mc146818rtc", + .property = "lost_tick_policy", + .value = "none", }, { /* end of list */ } }, @@ -740,6 +772,13 @@ static QEMUMachine xenfv_machine = { .init = pc_xen_hvm_init, .max_cpus = HVM_MAX_VCPUS, .default_machine_opts = "accel=xen", + .compat_props = (GlobalProperty[]) { + { + .driver = "mc146818rtc", + .property = "lost_tick_policy", + .value = "none", + }, + { /* end of list */ } }; #endif
The current value for the -rtc timedrift option is none. This patch makes sure that the old machines configuration will work the same way even after that option changes its default value. Signed-off-by: Crístian Viana <vianac@linux.vnet.ibm.com> --- hw/pc_piix.c | 39 +++++++++++++++++++++++++++++++++++++++ 1 files changed, 39 insertions(+), 0 deletions(-)