On Fri, 2008-07-25 at 02:22 +0300, Dor Laor wrote:
> Mark McLoughlin wrote:
> > 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.
...
> > -    if (n->tx_timer_active &&
> > -   (vq->vring.avail->idx - vq->last_avail_idx) == 64) {
> > +    if (n->tx_timer_active) {
> >   
> Actually it was worthless anyway since if we set the timer, the flag 
> below would have been cleared,
> causing the guest not to notify the host, thus the ==64 never called.

No, that's the point I'm trying to make in the commit message - the
guest ignores the NO_NOTIFY flag when the tx queue fills up and sends a
notification anyway.

The "== 64" test seems to be an attempt to catch this ring-full
condition.

Well, actually the test was worthless for a different reason, I guess.
If tx_timer_active is set and we get a notification, then given the
current guest code the number of buffers available should *always* be
64.

Cheers,
Mark.

--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to