virtio-net: drop assert on vm stop
On vm stop, vm_running state set to stopped before device is notified, so callbacks can get envoked with vm_running = false; and this is not an error. Cc: qemu-stable@nongnu.org Acked-by: Jason Wang <jasowang@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
This commit is contained in:
		
							parent
							
								
									abb4d5f2e2
								
							
						
					
					
						commit
						131c5221fe
					
				@ -1125,8 +1125,6 @@ static int32_t virtio_net_flush_tx(VirtIONetQueue *q)
 | 
				
			|||||||
        return num_packets;
 | 
					        return num_packets;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    assert(vdev->vm_running);
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
    if (q->async_tx.elem.out_num) {
 | 
					    if (q->async_tx.elem.out_num) {
 | 
				
			||||||
        virtio_queue_set_notification(q->tx_vq, 0);
 | 
					        virtio_queue_set_notification(q->tx_vq, 0);
 | 
				
			||||||
        return num_packets;
 | 
					        return num_packets;
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user