diff options
author | Peter Maydell <peter.maydell@linaro.org> | 2019-08-16 12:00:18 +0100 |
---|---|---|
committer | Peter Maydell <peter.maydell@linaro.org> | 2019-08-16 12:00:18 +0100 |
commit | 27608c7c66bd923eb5e5faab80e795408cbe2b51 (patch) | |
tree | ece1982460bc4a1f53833838337cb9fcb9fe5061 /hw | |
parent | f8f2eac4e5de8ce8ef17591ee1b84904437be25b (diff) | |
parent | 7dd59d01ddcc4a4ba0c44c2cc9e3b35c79aa7a29 (diff) |
Merge remote-tracking branch 'remotes/dgilbert/tags/pull-migration-20190814a' into staging
Migration pull 2019-08-15
Marcel's vmxnet3 live migraiton fix (that breaks vmxnet3 compatibility
but makes it work)
Error description improvements from Yury.
Multifd fixes from Ivan and Juan.
A load of small cleanups from Wei.
A small cleanup from Marc-André for a future patch.
# gpg: Signature made Wed 14 Aug 2019 19:00:39 BST
# gpg: using RSA key 45F5C71B4A0CB7FB977A9FA90516331EBC5BFDE7
# gpg: Good signature from "Dr. David Alan Gilbert (RH2) <dgilbert@redhat.com>" [full]
# Primary key fingerprint: 45F5 C71B 4A0C B7FB 977A 9FA9 0516 331E BC5B FDE7
* remotes/dgilbert/tags/pull-migration-20190814a: (33 commits)
migration: add some multifd traces
migration: Make global sem_sync semaphore by channel
migration: Add traces for multifd terminate threads
qemu-file: move qemu_{get,put}_counted_string() declarations
migration/postcopy: use mis->bh instead of allocating a QEMUBH
migration: rename migration_bitmap_sync_range to ramblock_sync_dirty_bitmap
migration: update ram_counters for multifd sync packet
migration: add speed limit for multifd migration
migration: add qemu_file_update_transfer interface
migration: always initialise ram_counters for a new migration
migration: remove unused field bytes_xfer
hmp: Remove migration capabilities from "info migrate"
migration/postcopy: use QEMU_IS_ALIGNED to replace host_offset
migration/postcopy: simplify calculation of run_start and fixup_start_addr
migration/postcopy: make PostcopyDiscardState a static variable
migration: extract ram_load_precopy
migration: return -EINVAL directly when version_id mismatch
migration: equation is more proper than and to check LOADVM_QUIT
migration: just pass RAMBlock is enough
migration: use migration_in_postcopy() to check POSTCOPY_ACTIVE
...
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'hw')
-rw-r--r-- | hw/net/vmxnet3.c | 52 |
1 files changed, 2 insertions, 50 deletions
diff --git a/hw/net/vmxnet3.c b/hw/net/vmxnet3.c index 10d01d0058..8b17548b02 100644 --- a/hw/net/vmxnet3.c +++ b/hw/net/vmxnet3.c @@ -2141,21 +2141,6 @@ vmxnet3_cleanup_msi(VMXNET3State *s) msi_uninit(d); } -static void -vmxnet3_msix_save(QEMUFile *f, void *opaque) -{ - PCIDevice *d = PCI_DEVICE(opaque); - msix_save(d, f); -} - -static int -vmxnet3_msix_load(QEMUFile *f, void *opaque, int version_id) -{ - PCIDevice *d = PCI_DEVICE(opaque); - msix_load(d, f); - return 0; -} - static const MemoryRegionOps b0_ops = { .read = vmxnet3_io_bar0_read, .write = vmxnet3_io_bar0_write, @@ -2176,11 +2161,6 @@ static const MemoryRegionOps b1_ops = { }, }; -static SaveVMHandlers savevm_vmxnet3_msix = { - .save_state = vmxnet3_msix_save, - .load_state = vmxnet3_msix_load, -}; - static uint64_t vmxnet3_device_serial_num(VMXNET3State *s) { uint64_t dsn_payload; @@ -2203,7 +2183,6 @@ static uint64_t vmxnet3_device_serial_num(VMXNET3State *s) static void vmxnet3_pci_realize(PCIDevice *pci_dev, Error **errp) { - DeviceState *dev = DEVICE(pci_dev); VMXNET3State *s = VMXNET3(pci_dev); int ret; @@ -2249,8 +2228,6 @@ static void vmxnet3_pci_realize(PCIDevice *pci_dev, Error **errp) pcie_dev_ser_num_init(pci_dev, VMXNET3_DSN_OFFSET, vmxnet3_device_serial_num(s)); } - - register_savevm_live(dev, "vmxnet3-msix", -1, 1, &savevm_vmxnet3_msix, s); } static void vmxnet3_instance_init(Object *obj) @@ -2440,29 +2417,6 @@ static const VMStateDescription vmstate_vmxnet3_int_state = { } }; -static bool vmxnet3_vmstate_need_pcie_device(void *opaque) -{ - VMXNET3State *s = VMXNET3(opaque); - - return !(s->compat_flags & VMXNET3_COMPAT_FLAG_DISABLE_PCIE); -} - -static bool vmxnet3_vmstate_test_pci_device(void *opaque, int version_id) -{ - return !vmxnet3_vmstate_need_pcie_device(opaque); -} - -static const VMStateDescription vmstate_vmxnet3_pcie_device = { - .name = "vmxnet3/pcie", - .version_id = 1, - .minimum_version_id = 1, - .needed = vmxnet3_vmstate_need_pcie_device, - .fields = (VMStateField[]) { - VMSTATE_PCI_DEVICE(parent_obj, VMXNET3State), - VMSTATE_END_OF_LIST() - } -}; - static const VMStateDescription vmstate_vmxnet3 = { .name = "vmxnet3", .version_id = 1, @@ -2470,9 +2424,8 @@ static const VMStateDescription vmstate_vmxnet3 = { .pre_save = vmxnet3_pre_save, .post_load = vmxnet3_post_load, .fields = (VMStateField[]) { - VMSTATE_STRUCT_TEST(parent_obj, VMXNET3State, - vmxnet3_vmstate_test_pci_device, 0, - vmstate_pci_device, PCIDevice), + VMSTATE_PCI_DEVICE(parent_obj, VMXNET3State), + VMSTATE_MSIX(parent_obj, VMXNET3State), VMSTATE_BOOL(rx_packets_compound, VMXNET3State), VMSTATE_BOOL(rx_vlan_stripping, VMXNET3State), VMSTATE_BOOL(lro_supported, VMXNET3State), @@ -2508,7 +2461,6 @@ static const VMStateDescription vmstate_vmxnet3 = { }, .subsections = (const VMStateDescription*[]) { &vmxstate_vmxnet3_mcast_list, - &vmstate_vmxnet3_pcie_device, NULL } }; |