Skip to content

Commit

Permalink
net: skip virtio-net config of deleted nic's peers
Browse files Browse the repository at this point in the history
https://bugzilla.redhat.com/show_bug.cgi?id=1373816
qemu core dump happens during repetitive unpug-plug
with multiple queues and Windows RSS-capable guest.
If back-end delete requested during virtio-net device
initialization, driver still can try configure the device
for multiple queues. The virtio-net device is expected
to be removed as soon as the initialization is done.

Signed-off-by: Yuri Benditovich <[email protected]>
Signed-off-by: Jason Wang <[email protected]>
  • Loading branch information
ybendito authored and jasowang committed Nov 15, 2016
1 parent 682df58 commit 68b5f31
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions hw/net/virtio-net.c
Original file line number Diff line number Diff line change
Expand Up @@ -508,6 +508,10 @@ static void virtio_net_set_queues(VirtIONet *n)
int i;
int r;

if (n->nic->peer_deleted) {
return;
}

for (i = 0; i < n->max_queues; i++) {
if (i < n->curr_queues) {
r = peer_attach(n, i);
Expand Down

0 comments on commit 68b5f31

Please sign in to comment.