qemu/hw/virtio
Michael S. Tsirkin 68a27b208a virtio-pci: fix migration for pci bus master
Current support for bus master (clearing OK bit) together with the need to
support guests which do not enable PCI bus mastering, leads to extra state in
VIRTIO_PCI_FLAG_BUS_MASTER_BUG bit, which isn't robust in case of cross-version
migration for the case when guests use the device before setting DRIVER_OK.

Rip out this code, and replace it:
-   Modern QEMU doesn't need VIRTIO_PCI_FLAG_BUS_MASTER_BUG
    so just drop it for latest machine type.
-   For compat machine types, set PCI_COMMAND if DRIVER_OK
    is set.

As this is needed for 2.1 for both pc and ppc, move PC_COMPAT macros from pc.h
to a new common header.

Cc: Greg Kurz <gkurz@linux.vnet.ibm.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Reviewed-by: Alexander Graf <agraf@suse.de>
2014-11-02 12:03:03 +02:00
..
dataplane vring: Better error handling if num is too large 2014-09-22 11:39:49 +01:00
Makefile.objs block: Always compile virtio-blk dataplane 2014-09-22 11:39:51 +01:00
vhost-backend.c virtio: Move extern declaration to header file 2014-08-09 00:06:32 +04:00
vhost-user.c vhost-user: minor cleanups 2014-07-18 02:22:24 +03:00
vhost.c vhost_net: start/stop guest notifiers properly 2014-09-03 16:40:44 +03:00
virtio-balloon.c virtio-balloon: Tweak recent fix for integer overflow 2014-10-23 09:01:29 -04:00
virtio-bus.c virtio-bus: cleanup plug/unplug interface 2013-12-09 21:46:48 +01:00
virtio-mmio.c virtio-mmio: Drop useless bus->allow_hotplug = 0 2014-10-15 05:03:13 +02:00
virtio-pci.c virtio-pci: fix migration for pci bus master 2014-11-02 12:03:03 +02:00
virtio-pci.h virtio-pci: fix migration for pci bus master 2014-11-02 12:03:03 +02:00
virtio-rng.c virtio-rng: add some trace events 2014-08-12 14:29:55 +01:00
virtio.c virtio: add a wrapper for virtio-backend initialization 2014-09-30 11:09:59 +02:00