ide save/restore current transfer fields
commit42ee76fe82093ba914f0dc83d2decbcf68866144
authorMarcelo Tosatti <mtosatti@redhat.com>
Wed, 20 Jan 2010 17:01:49 +0000 (20 18:01 +0100)
committerAnthony Liguori <aliguori@us.ibm.com>
Tue, 26 Jan 2010 21:42:02 +0000 (26 15:42 -0600)
treed58c91e6d6e75bf9006cd45923603503416d5fbd
parentd5e4acf7dfa1786c3825632362f5a73631d1eb55
ide save/restore current transfer fields

If migration takes place between write of the bmdma address register and
write of the command register (to initiate DMA), the destination will
not properly start the DMA op, hanging the guest:

ata1.00: exception Emask 0x0 SAct 0x0 SErr 0x0 action 0x6 frozen
ata1.00: cmd c8/00:16:41:00:00/00:00:00:00:00/e0 tag 0 dma 11264 in
         res 40/00:00:00:00:00/00:00:00:00:00/00 Emask 0x4 (timeout)
ata1.00: status: { DRDY }

Fix by sending current transfer information in the migration data.

We need to update ide version to 4 for this to work.  As we don't
have subsectios, we need to chain the update increase until
vmstate_ide_pci (quintela)

Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
Signed-off-by: Juan Quintela <quintela@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
hw/ide/pci.c