From a011b10e0c385c58469e654595801a592fb4137a Mon Sep 17 00:00:00 2001 From: Alex Williamson Date: Wed, 17 Oct 2012 11:20:11 -0600 Subject: [PATCH 1/2] vfio-pci: Fix debug build Stray variable from before MSI-X rework Signed-off-by: Alex Williamson --- hw/vfio_pci.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/hw/vfio_pci.c b/hw/vfio_pci.c index 639371e7a2..0619af4854 100644 --- a/hw/vfio_pci.c +++ b/hw/vfio_pci.c @@ -639,9 +639,8 @@ static void vfio_disable_msix(VFIODevice *vdev) vfio_disable_msi_common(vdev); - DPRINTF("%s(%04x:%02x:%02x.%x, msi%s)\n", __func__, - vdev->host.domain, vdev->host.bus, vdev->host.slot, - vdev->host.function, msix ? "x" : ""); + DPRINTF("%s(%04x:%02x:%02x.%x)\n", __func__, vdev->host.domain, + vdev->host.bus, vdev->host.slot, vdev->host.function); } static void vfio_disable_msi(VFIODevice *vdev) From d9f0e63898d639629bb7eb914786529185334635 Mon Sep 17 00:00:00 2001 From: Alex Williamson Date: Wed, 17 Oct 2012 11:20:14 -0600 Subject: [PATCH 2/2] vfio-pci: Mark non-migratable We haven't magically fixed this yet. Toss in a description too. Signed-off-by: Alex Williamson --- hw/vfio_pci.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/hw/vfio_pci.c b/hw/vfio_pci.c index 0619af4854..d5ff367c1b 100644 --- a/hw/vfio_pci.c +++ b/hw/vfio_pci.c @@ -1946,6 +1946,10 @@ static Property vfio_pci_dev_properties[] = { DEFINE_PROP_END_OF_LIST(), }; +static const VMStateDescription vfio_pci_vmstate = { + .name = "vfio-pci", + .unmigratable = 1, +}; static void vfio_pci_dev_class_init(ObjectClass *klass, void *data) { @@ -1954,6 +1958,8 @@ static void vfio_pci_dev_class_init(ObjectClass *klass, void *data) dc->reset = vfio_pci_reset; dc->props = vfio_pci_dev_properties; + dc->vmsd = &vfio_pci_vmstate; + dc->desc = "VFIO-based PCI device assignment"; pdc->init = vfio_initfn; pdc->exit = vfio_exitfn; pdc->config_read = vfio_pci_read_config;