migration: failover: reset partially_hotplugged
authorLaurent Vivier <lvivier@redhat.com>
Tue, 29 Jun 2021 15:29:37 +0000 (17:29 +0200)
committerMichael S. Tsirkin <mst@redhat.com>
Sat, 3 Jul 2021 07:12:35 +0000 (03:12 -0400)
When the card is plugged back, reset the partially_hotplugged flag to false

Bug: https://bugzilla.redhat.com/show_bug.cgi?id=1787194
Signed-off-by: Laurent Vivier <lvivier@redhat.com>
Message-Id: <20210629152937.619193-1-lvivier@redhat.com>
Reviewed-by: Juan Quintela <quintela@redhat.com>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
hw/net/virtio-net.c

index bd7958b9f0eed2705e0d6a2feaeaefb5e63bd6a4..16d20cdee52ad6fbf1fdb4501483b2428332ea9c 100644 (file)
@@ -3234,6 +3234,7 @@ static bool failover_replug_primary(VirtIONet *n, DeviceState *dev,
         }
         hotplug_handler_plug(hotplug_ctrl, dev, &err);
     }
+    pdev->partially_hotplugged = false;
 
 out:
     error_propagate(errp, err);