qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] broken backward migration due to commit 461a275 "parallel: adding vmstate for save/restore"
@ 2014-12-19 11:03 Igor Mammedov
  2014-12-19 11:15 ` Paolo Bonzini
  0 siblings, 1 reply; 9+ messages in thread
From: Igor Mammedov @ 2014-12-19 11:03 UTC (permalink / raw)
  To: qemu-devel; +Cc: pbonzini, dgilbert, Pavel.Dovgaluk, quintela

steps to reproduce:

Current master source:
qemu-system-x86_64 -monitor stdio -M pc-i440fx-2.1
(qemu) stop
(qemu) migrate "exec:gzip -c > STATEFILE.gz"

Target:
  qemu-system-x86_64-2.1 -monitor stdio -M pc-i440fx-2.1 -incoming "exec: gzip -c -d STATEFILE.gz"

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [Qemu-devel] broken backward migration due to commit 461a275 "parallel: adding vmstate for save/restore"
  2014-12-19 11:03 [Qemu-devel] broken backward migration due to commit 461a275 "parallel: adding vmstate for save/restore" Igor Mammedov
@ 2014-12-19 11:15 ` Paolo Bonzini
  2014-12-19 11:32   ` Igor Mammedov
  0 siblings, 1 reply; 9+ messages in thread
From: Paolo Bonzini @ 2014-12-19 11:15 UTC (permalink / raw)
  To: Igor Mammedov, qemu-devel; +Cc: dgilbert, Pavel.Dovgaluk, quintela



On 19/12/2014 12:03, Igor Mammedov wrote:
> steps to reproduce:
> 
> Current master source:
> qemu-system-x86_64 -monitor stdio -M pc-i440fx-2.1
> (qemu) stop
> (qemu) migrate "exec:gzip -c > STATEFILE.gz"
> 
> Target:
>   qemu-system-x86_64-2.1 -monitor stdio -M pc-i440fx-2.1 -incoming "exec: gzip -c -d STATEFILE.gz"
> 

That's expected.  Backwards migration is not supported by upstream, and
there's no equivalent of subsections for entire devices.

Just use "-parallel none".

Paolo

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [Qemu-devel] broken backward migration due to commit 461a275 "parallel: adding vmstate for save/restore"
  2014-12-19 11:15 ` Paolo Bonzini
@ 2014-12-19 11:32   ` Igor Mammedov
  2014-12-19 11:39     ` Igor Mammedov
  2014-12-19 12:02     ` Paolo Bonzini
  0 siblings, 2 replies; 9+ messages in thread
From: Igor Mammedov @ 2014-12-19 11:32 UTC (permalink / raw)
  To: Paolo Bonzini; +Cc: dgilbert, qemu-devel, Pavel.Dovgaluk, quintela

On Fri, 19 Dec 2014 12:15:20 +0100
Paolo Bonzini <pbonzini@redhat.com> wrote:

> 
> 
> On 19/12/2014 12:03, Igor Mammedov wrote:
> > steps to reproduce:
> > 
> > Current master source:
> > qemu-system-x86_64 -monitor stdio -M pc-i440fx-2.1
> > (qemu) stop
> > (qemu) migrate "exec:gzip -c > STATEFILE.gz"
> > 
> > Target:
> >   qemu-system-x86_64-2.1 -monitor stdio -M pc-i440fx-2.1 -incoming "exec: gzip -c -d STATEFILE.gz"
> > 
> 
> That's expected.  Backwards migration is not supported by upstream, and
> there's no equivalent of subsections for entire devices.
> 
> Just use "-parallel none".
ok

There is one more commit that breaks it, this time with subsection
6c3bff0 "exec: Save CPUState::exception_index field"

qemu: warning: error while loading state for instance 0x0 of device 'cpu_common'
the same reproducer with -parallel none

> 
> Paolo

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [Qemu-devel] broken backward migration due to commit 461a275 "parallel: adding vmstate for save/restore"
  2014-12-19 11:32   ` Igor Mammedov
@ 2014-12-19 11:39     ` Igor Mammedov
  2014-12-19 12:02     ` Paolo Bonzini
  1 sibling, 0 replies; 9+ messages in thread
From: Igor Mammedov @ 2014-12-19 11:39 UTC (permalink / raw)
  To: Paolo Bonzini; +Cc: quintela, dgilbert, Pavel.Dovgaluk, qemu-devel

On Fri, 19 Dec 2014 12:32:52 +0100
Igor Mammedov <imammedo@redhat.com> wrote:

> On Fri, 19 Dec 2014 12:15:20 +0100
> Paolo Bonzini <pbonzini@redhat.com> wrote:
> 
> > 
> > 
> > On 19/12/2014 12:03, Igor Mammedov wrote:
> > > steps to reproduce:
> > > 
> > > Current master source:
> > > qemu-system-x86_64 -monitor stdio -M pc-i440fx-2.1
> > > (qemu) stop
> > > (qemu) migrate "exec:gzip -c > STATEFILE.gz"
> > > 
> > > Target:
> > >   qemu-system-x86_64-2.1 -monitor stdio -M pc-i440fx-2.1 -incoming "exec: gzip -c -d STATEFILE.gz"
> > > 
> > 
> > That's expected.  Backwards migration is not supported by upstream, and
> > there's no equivalent of subsections for entire devices.
> > 
> > Just use "-parallel none".
> ok
> 
> There is one more commit that breaks it, this time with subsection
> 6c3bff0 "exec: Save CPUState::exception_index field"
> 
> qemu: warning: error while loading state for instance 0x0 of device 'cpu_common'
> the same reproducer with -parallel none
correction this time it's with -M pc-i440fx-1.7 and target qemu-1.7

> 
> > 
> > Paolo
> 
> 

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [Qemu-devel] broken backward migration due to commit 461a275 "parallel: adding vmstate for save/restore"
  2014-12-19 11:32   ` Igor Mammedov
  2014-12-19 11:39     ` Igor Mammedov
@ 2014-12-19 12:02     ` Paolo Bonzini
  2014-12-19 12:42       ` Igor Mammedov
  1 sibling, 1 reply; 9+ messages in thread
From: Paolo Bonzini @ 2014-12-19 12:02 UTC (permalink / raw)
  To: Igor Mammedov; +Cc: quintela, dgilbert, Pavel.Dovgaluk, qemu-devel



On 19/12/2014 12:32, Igor Mammedov wrote:
> There is one more commit that breaks it, this time with subsection
> 6c3bff0 "exec: Save CPUState::exception_index field"
> 
> qemu: warning: error while loading state for instance 0x0 of device 'cpu_common'
> the same reproducer with -parallel none

Patch sent, thanks.

Paolo

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [Qemu-devel] broken backward migration due to commit 461a275 "parallel: adding vmstate for save/restore"
  2014-12-19 12:02     ` Paolo Bonzini
@ 2014-12-19 12:42       ` Igor Mammedov
  2014-12-19 12:49         ` Igor Mammedov
  2014-12-19 13:10         ` Paolo Bonzini
  0 siblings, 2 replies; 9+ messages in thread
From: Igor Mammedov @ 2014-12-19 12:42 UTC (permalink / raw)
  To: Paolo Bonzini; +Cc: quintela, dgilbert, Pavel.Dovgaluk, qemu-devel

On Fri, 19 Dec 2014 13:02:24 +0100
Paolo Bonzini <pbonzini@redhat.com> wrote:

> 
> 
> On 19/12/2014 12:32, Igor Mammedov wrote:
> > There is one more commit that breaks it, this time with subsection
> > 6c3bff0 "exec: Save CPUState::exception_index field"
> > 
> > qemu: warning: error while loading state for instance 0x0 of device 'cpu_common'
> > the same reproducer with -parallel none
> 
> Patch sent, thanks.
> 
> Paolo

one more breakage:
a28fe7e pckbd: adding new fields to vmstate

source:
qemu-system-x86_64 -monitor stdio -M pc-i440fx-1.7 -parallel none xpsp3x86.qcow2

switch to text screen where you could select Safe Mode and stop/migrate at this point

target:
qemu-system-x86_64-1.7 -monitor stdio -M pc-i440fx-1.7 -incoming "exec: gzip -c -d STATEFILE.gz" xpsp3x86.qcow2

qemu: warning: error while loading state for instance 0x0 of device 'pckbd'

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [Qemu-devel] broken backward migration due to commit 461a275 "parallel: adding vmstate for save/restore"
  2014-12-19 12:42       ` Igor Mammedov
@ 2014-12-19 12:49         ` Igor Mammedov
  2014-12-19 13:21           ` Paolo Bonzini
  2014-12-19 13:10         ` Paolo Bonzini
  1 sibling, 1 reply; 9+ messages in thread
From: Igor Mammedov @ 2014-12-19 12:49 UTC (permalink / raw)
  To: Paolo Bonzini; +Cc: qemu-devel, dgilbert, Pavel.Dovgaluk, quintela

On Fri, 19 Dec 2014 13:42:37 +0100
Igor Mammedov <imammedo@redhat.com> wrote:

> On Fri, 19 Dec 2014 13:02:24 +0100
> Paolo Bonzini <pbonzini@redhat.com> wrote:
> 
> > 
> > 
> > On 19/12/2014 12:32, Igor Mammedov wrote:
> > > There is one more commit that breaks it, this time with subsection
> > > 6c3bff0 "exec: Save CPUState::exception_index field"
> > > 
> > > qemu: warning: error while loading state for instance 0x0 of device 'cpu_common'
> > > the same reproducer with -parallel none
> > 
> > Patch sent, thanks.
> > 
> > Paolo
> 
> one more breakage:
> a28fe7e pckbd: adding new fields to vmstate
> 
> source:
> qemu-system-x86_64 -monitor stdio -M pc-i440fx-1.7 -parallel none xpsp3x86.qcow2
> 
> switch to text screen where you could select Safe Mode and stop/migrate at this point

one more issue if you continue normal boot and wait till XP is booted and then migrate
the target will error out with:

qemu: warning: error while loading state for instance 0x0 of device 'serial'

> 
> target:
> qemu-system-x86_64-1.7 -monitor stdio -M pc-i440fx-1.7 -incoming "exec: gzip -c -d STATEFILE.gz" xpsp3x86.qcow2
> 
> qemu: warning: error while loading state for instance 0x0 of device 'pckbd'
> 

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [Qemu-devel] broken backward migration due to commit 461a275 "parallel: adding vmstate for save/restore"
  2014-12-19 12:42       ` Igor Mammedov
  2014-12-19 12:49         ` Igor Mammedov
@ 2014-12-19 13:10         ` Paolo Bonzini
  1 sibling, 0 replies; 9+ messages in thread
From: Paolo Bonzini @ 2014-12-19 13:10 UTC (permalink / raw)
  To: Igor Mammedov; +Cc: quintela, dgilbert, Pavel.Dovgaluk, qemu-devel



On 19/12/2014 13:42, Igor Mammedov wrote:
> On Fri, 19 Dec 2014 13:02:24 +0100
> Paolo Bonzini <pbonzini@redhat.com> wrote:
> 
>>
>>
>> On 19/12/2014 12:32, Igor Mammedov wrote:
>>> There is one more commit that breaks it, this time with subsection
>>> 6c3bff0 "exec: Save CPUState::exception_index field"
>>>
>>> qemu: warning: error while loading state for instance 0x0 of device 'cpu_common'
>>> the same reproducer with -parallel none
>>
>> Patch sent, thanks.
>>
>> Paolo
> 
> one more breakage:
> a28fe7e pckbd: adding new fields to vmstate
> 
> source:
> qemu-system-x86_64 -monitor stdio -M pc-i440fx-1.7 -parallel none xpsp3x86.qcow2
> 
> switch to text screen where you could select Safe Mode and stop/migrate at this point
> 
> target:
> qemu-system-x86_64-1.7 -monitor stdio -M pc-i440fx-1.7 -incoming "exec: gzip -c -d STATEFILE.gz" xpsp3x86.qcow2
> 
> qemu: warning: error while loading state for instance 0x0 of device 'pckbd'

Looks like Windows (all versions) writes 0xDD and 0xDF to the outport
port of the keyboard controller when it enables/disables the A20 line.
There are two possibilities:

1) disable this if you care about backwards-migration

2) apply upstream a patch like this:

diff --git a/hw/input/pckbd.c b/hw/input/pckbd.c
index 2b0cd3d..cb4a8be 100644
--- a/hw/input/pckbd.c
+++ b/hw/input/pckbd.c
@@ -373,7 +373,7 @@ static void kbd_reset(void *opaque)

 static uint8_t kbd_outport_default(KBDState *s)
 {
-    return KBD_OUT_RESET | KBD_OUT_A20
+    return (0xdf & ~KBD_OUT_OBF & ~KBD_OUT_MOUSE_OBF)
            | (s->status & KBD_STAT_OBF ? KBD_OUT_OBF : 0)
            | (s->status & KBD_STAT_MOUSE_OBF ? KBD_OUT_MOUSE_OBF : 0);
 }

3) do both, so upstream works better

Paolo

^ permalink raw reply related	[flat|nested] 9+ messages in thread

* Re: [Qemu-devel] broken backward migration due to commit 461a275 "parallel: adding vmstate for save/restore"
  2014-12-19 12:49         ` Igor Mammedov
@ 2014-12-19 13:21           ` Paolo Bonzini
  0 siblings, 0 replies; 9+ messages in thread
From: Paolo Bonzini @ 2014-12-19 13:21 UTC (permalink / raw)
  To: Igor Mammedov; +Cc: qemu-devel, dgilbert, Pavel.Dovgaluk, quintela



On 19/12/2014 13:49, Igor Mammedov wrote:
>> source:
>> qemu-system-x86_64 -monitor stdio -M pc-i440fx-1.7 -parallel none xpsp3x86.qcow2
>>
>> switch to text screen where you could select Safe Mode and stop/migrate at this point
> 
> one more issue if you continue normal boot and wait till XP is booted and then migrate
> the target will error out with:
> 
> qemu: warning: error while loading state for instance 0x0 of device 'serial'

I cannot reproduce this.

Paolo

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2014-12-19 13:21 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-12-19 11:03 [Qemu-devel] broken backward migration due to commit 461a275 "parallel: adding vmstate for save/restore" Igor Mammedov
2014-12-19 11:15 ` Paolo Bonzini
2014-12-19 11:32   ` Igor Mammedov
2014-12-19 11:39     ` Igor Mammedov
2014-12-19 12:02     ` Paolo Bonzini
2014-12-19 12:42       ` Igor Mammedov
2014-12-19 12:49         ` Igor Mammedov
2014-12-19 13:21           ` Paolo Bonzini
2014-12-19 13:10         ` Paolo Bonzini

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).