[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <49D5F2FA.9040107@novell.com>
Date: Fri, 03 Apr 2009 07:28:58 -0400
From: Gregory Haskins <ghaskins@...ell.com>
To: Gerd Hoffmann <kraxel@...hat.com>
CC: Avi Kivity <avi@...hat.com>,
Herbert Xu <herbert@...dor.apana.org.au>,
anthony@...emonkey.ws, andi@...stfloor.org,
linux-kernel@...r.kernel.org, agraf@...e.de, pmullaney@...ell.com,
pmorreale@...ell.com, rusty@...tcorp.com.au,
netdev@...r.kernel.org, kvm@...r.kernel.org
Subject: Re: [RFC PATCH 00/17] virtual-bus
Gerd Hoffmann wrote:
> Avi Kivity wrote:
>
>> There is no choice. Exiting from the guest to the kernel to userspace
>> is prohibitively expensive, you can't do that on every packet.
>>
>
> I didn't look at virtio-net very closely yet. I wonder why the
> notification is that a big issue though. It is easy to keep the number
> of notifications low without increasing latency:
>
> Check shared ring status when stuffing a request. If there are requests
> not (yet) consumed by the other end there is no need to send a
> notification. That scheme can even span multiple rings (nics with rx
> and tx for example).
>
FWIW: I employ this scheme. The shm-signal construct has a "dirty" and
"pending" flag (all on the same cacheline, which may or may not address
Andi's later point). The first time you dirty the shm, it sets both
flags. The consumer side has to clear "pending" before any subsequent
signals are sent. Normally the consumer side will also clear "enabled"
(as part of the bidir napi thing) to further disable signals.
-Greg
Download attachment "signature.asc" of type "application/pgp-signature" (258 bytes)
Powered by blists - more mailing lists