Skip to content

RFC Save state error handling (kill off no_migrate)

Alex Williamson qemu-devel 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 RFC Latest5 patches 6 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/5savevm: Allow SaveStateHandler() to return errorhw/adb.c hw/ads7846.c hw/arm_gic.c +64 more+219 -840 replies
2/5savevm: Remove register_device_unmigratable()hw/hw.h hw/ivshmem.c savevm.c+5 -370 replies
3/5savevm: Allow vmsd->pre_save to return errorhw/fdc.c hw/hpet.c hw/hw.h +10 more+49 -290 replies
4/5pci: Allow pci_device_save() to return errorhw/grackle_pci.c hw/gt64xxx.c hw/ivshmem.c +7 more+24 -210 replies
5/5virtio: Allow virtio_save() errorshw/virtio-balloon.c hw/virtio-blk.c hw/virtio-net.c +4 more+34 -120 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [Qemu-devel] [RFC PATCH 0/5] Save state error handling (kill off no_migrate)

I was thinking of making KVM VMs with assigned PCI devices unsavable/unmigratable, but I wasn't thrilled with the no_migrate solutions. The more generic solutions seems to be simply letting save handlers return an error if the device can't be migrated. This is also much more generic than a one-way bit flip of the no_migrate flag. For a vmsd based registration, the pre_save() routine seems to be the right place to allow devices to abort. The series also carries the error back through all the vmstate callers. If this looks good, I'll give it some more testing and submit as non-RFC. Thanks,

Alex

---

Alex Williamson (5):
virtio: Allow virtio_save() errors
pci: Allow pci_device_save() to return error
savevm: Allow vmsd->pre_save to return error
savevm: Remove register_device_unmigratable()
savevm: Allow SaveStateHandler() to return error

 hw/adb.c                    |    8 ++++-
 hw/ads7846.c                |    4 ++-
 hw/arm_gic.c                |    4 ++-
 hw/arm_timer.c              |    6 +++-
 hw/armv7m_nvic.c            |    4 ++-
 hw/cuda.c                   |    4 ++-
 hw/fdc.c                    |    3 +-
 hw/g364fb.c                 |    4 ++-
 hw/grackle_pci.c            |    4 +--
 hw/gt64xxx.c                |    4 +--
 hw/heathrow_pic.c           |    4 ++-
 hw/hpet.c                   |    3 +-
 hw/hw.h                     |   10 +++---
 hw/i2c.c                    |    3 +-
 hw/ide/core.c               |    4 ++-
 hw/ivshmem.c                |   17 +++++++----
 hw/lsi53c895a.c             |    4 ++-
 hw/m48t59.c                 |    4 ++-
 hw/mac_dbdma.c              |    4 ++-
 hw/mac_nvram.c              |    4 ++-
 hw/max111x.c                |    4 ++-
 hw/mipsnet.c                |    4 ++-
 hw/mst_fpga.c               |    3 +-
 hw/nand.c                   |    3 +-
 hw/openpic.c                |    4 +--
 hw/pci.c                    |    8 ++++-
 hw/pci.h                    |    2 +
 hw/piix4.c                  |    4 +--
 hw/pl011.c                  |    4 ++-
 hw/pl022.c                  |    4 ++-
 hw/pl061.c                  |    4 ++-
 hw/ppc4xx_pci.c             |   10 ++++--
 hw/ppce500_pci.c            |   10 ++++--
 hw/pxa2xx.c                 |   28 +++++++++++++-----
 hw/pxa2xx_dma.c             |    4 ++-
 hw/pxa2xx_gpio.c            |    4 ++-
 hw/pxa2xx_keypad.c          |    3 +-
 hw/pxa2xx_lcd.c             |    4 ++-
 hw/pxa2xx_mmci.c            |    4 ++-
 hw/pxa2xx_pic.c             |    4 ++-
 hw/pxa2xx_timer.c           |    4 ++-
 hw/rc4030.c                 |    4 ++-
 hw/rtl8139.c                |    4 ++-
 hw/serial.c                 |    3 +-
 hw/spitz.c                  |   14 ++++++---
 hw/ssd0323.c                |    4 ++-
 hw/ssi-sd.c                 |    4 ++-
 hw/stellaris.c              |   20 ++++++++++---
 hw/stellaris_enet.c         |    4 ++-
 hw/stellaris_input.c        |    4 ++-
 hw/syborg_fb.c              |    4 ++-
 hw/syborg_interrupt.c       |    3 +-
 hw/syborg_keyboard.c        |    3 +-
 hw/syborg_pointer.c         |    3 +-
 hw/syborg_rtc.c             |    4 ++-
 hw/syborg_serial.c          |    4 ++-
 hw/syborg_timer.c           |    4 ++-
 hw/tsc2005.c                |    4 ++-
 hw/tsc210x.c                |    4 ++-
 hw/twl92230.c               |    3 +-
 hw/unin_pci.c               |    4 +--
 hw/usb-uhci.c               |    3 +-
 hw/virtio-balloon.c         |    8 ++++-
 hw/virtio-blk.c             |    9 ++++--
 hw/virtio-net.c             |    9 ++++--
 hw/virtio-pci.c             |    9 ++++--
 hw/virtio-serial-bus.c      |    9 ++++--
 hw/virtio.c                 |   13 ++++++--
 hw/virtio.h                 |    4 +--
 hw/wm8750.c                 |    3 +-
 hw/zaurus.c                 |    4 ++-
 qemu-common.h               |    2 +
 savevm.c                    |   67 +++++++++++++------------------------------
 slirp/slirp.c               |    6 +++-
 target-arm/machine.c        |    3 +-
 target-cris/machine.c       |    3 +-
 target-i386/machine.c       |    7 +++-
 target-microblaze/machine.c |    3 +-
 target-mips/machine.c       |    3 +-
 target-ppc/machine.c        |    3 +-
 target-s390x/machine.c      |    3 +-
 target-sparc/machine.c      |    3 +-
 82 files changed, 322 insertions(+), 174 deletions(-)