[Top] [All Lists]

Re: RFC: NAPI packet weighting patch

To: mitch.a.williams@xxxxxxxxx
Subject: Re: RFC: NAPI packet weighting patch
From: "David S. Miller" <davem@xxxxxxxxxxxxx>
Date: Fri, 03 Jun 2005 13:22:57 -0700 (PDT)
Cc: hadi@xxxxxxxxxx, john.ronciak@xxxxxxxxx, jdmason@xxxxxxxxxx, shemminger@xxxxxxxx, netdev@xxxxxxxxxxx, Robert.Olsson@xxxxxxxxxxx, ganesh.venkatesan@xxxxxxxxx, jesse.brandeburg@xxxxxxxxx
In-reply-to: <Pine.CYG.4.58.0506031202280.3344@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx>
References: <1117824150.6071.34.camel@xxxxxxxxxxxxxxxxxxxxx> <20050603.120126.41874584.davem@xxxxxxxxxxxxx> <Pine.CYG.4.58.0506031202280.3344@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx>
Sender: netdev-bounce@xxxxxxxxxxx
From: Mitch Williams <mitch.a.williams@xxxxxxxxx>
Date: Fri, 3 Jun 2005 12:28:10 -0700

> In a typical NAPI polling loop, the driver processes receive packets until
> it either hits the quota or runs out of packets.  Then, at the end of the
> loop, it returns all of those now-free receive resources back to the
> hardware.
> With a heavy receive load, the hardware will run out of receive
> descriptors in the time it takes the driver/NAPI/stack to process 64
> packets.  So it drops them on the floor.  And, as we know, dropped packets
> are A Bad Thing.

This is why you should replenish RX packets _IN_ your
RX packet receive processing, not via some tasklet
or other seperate work processing context.

No wonder I never see this on tg3.

It is the only way to do this cleanly.

<Prev in Thread] Current Thread [Next in Thread>