Remove virtio_net tx ring-full heuristic
commit102f29c3a03f4643cda3cee0482b1f410888d60e
authorMark McLoughlin <markmc@redhat.com>
Mon, 11 Aug 2008 20:12:05 +0000 (11 21:12 +0100)
committerAvi Kivity <avi@qumranet.com>
Wed, 13 Aug 2008 09:12:02 +0000 (13 12:12 +0300)
tree67b9f35760bdec69d56553f9c1ec89950e9870ee
parent2fffe310f910aa136a9d170f1710a5a4c5c0ad50
Remove virtio_net tx ring-full heuristic

virtio_net tries to guess when it has received a tx
notification from the guest whether it indicates that the
guest has no more room in the tx ring and it should
immediately flush the queued buffers.

The heuristic is based on the fact that there are 128
buffer entries in the ring and each packet uses 2 buffers
(i.e. the virtio_net_hdr and the packet's linear data).

Using GSO or increasing the size of the rings will break
that heuristic, so let's remove it and assume that any
notification from the guest after we've disabled
notifications indicates that we should flush our buffers.

Signed-off-by: Mark McLoughlin <markmc@redhat.com>
Signed-off-by: Avi Kivity <avi@qumranet.com>
hw/virtio-net.c