]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
[bhyve] virtio-net: Do not allow receiving packets until features have been negotiated.
authorafedorov <afedorov@FreeBSD.org>
Thu, 17 Dec 2020 16:52:40 +0000 (16:52 +0000)
committerafedorov <afedorov@FreeBSD.org>
Thu, 17 Dec 2020 16:52:40 +0000 (16:52 +0000)
commit29679793ce902ec743996cf3666be398c877f045
tree7237a57d178eecced4f80999f498af9b0e8b2ceb
parent188e59845a5b001c897064ef31c87b6e22669581
[bhyve] virtio-net: Do not allow receiving packets until features have been negotiated.

Enforce the requirement that the RX callback cannot be called after a reset until the features have been negotiated.
This fixes a race condition where the receive callback is called during a device reset.

Reviewed by: vmaffione, grehan
Approved by: vmaffione (mentor)
Sponsored by: vstack.com
Differential Revision: https://reviews.freebsd.org/D27381
usr.sbin/bhyve/pci_virtio_net.c