From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jeremy Fitzhardinge Subject: Re: [PATCH] VNIF: Using smart polling instead of event notification. Date: Fri, 02 Oct 2009 12:10:00 -0700 Message-ID: <4AC65008.20307@goop.org> References: <1254476489.12198.27.camel@zakaz.uk.xensource.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-15 Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <1254476489.12198.27.camel@zakaz.uk.xensource.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Ian Campbell Cc: "Xu, Dongxiao" , "xen-devel@lists.xensource.com" , Keir Fraser List-Id: xen-devel@lists.xenproject.org On 10/02/09 02:41, Ian Campbell wrote: > On Thu, 2009-10-01 at 15:02 +0100, Xu, Dongxiao wrote: > >> We found that the event notification frequency is still high in some network cases. NAPI polls only for a little >> time slot and does not efficient enough in our backend/frontend case. Actually our patch repeated calling NAPI >> interface to do more polling, and netback will NOT notify netfront during this period. Once netfront polling out >> all the data, and finds that there is no more data arrive/send during the next 100ms, the timer will stop working >> to end the polling. >> > Isn't that an argument for improving NAPI rather than coding workarounds > into each driver? As physical NICs increase in speed it seems like NAPI > will need to increase its efficiency in a similar manner. > > It would be interesting to run the patches past netdev@vger. > Yes. NAPI is intended to address precisely this issue, so it should be made to work. >> This filed 'smart_poll_active' is shared by netfront and netback, >> to indicate whether netfront is polling data. >> So this filed is necessary for netback to notify netfront if this flag >> is not set. >> > Right, but that doesn't justify sticking a netfront specific field in a > generic ring structure. > This kind of poll/interrupt switch isn't network-specific though; this just happens to be the first user. Presumably other devices with a high rate of small messages could also take advantage of it. J