lkml.org 
[lkml]   [2012]   [Mar]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH v4] lpc32xx: Added ethernet driver
From
Date
On Mon, 2012-03-05 at 16:49 -0800, Eric Dumazet wrote:
> On Mon, 2012-03-05 at 22:45 +0000, Ben Hutchings wrote:
> > On Mon, 2012-03-05 at 22:40 +0100, Roland Stigge wrote:
> > [...]
>
> ...
>
> > > + /* Copy packet from buffer */
> > > + memcpy(prdbuf,
> > > + pldat->rx_buff_v[rxconsidx], len);
> > > +
> > > + /* Pass to upper layer */
> > > + skb->protocol = eth_type_trans(skb, ndev);
> > > + netif_rx(skb);
> > > + ndev->last_rx = jiffies;
> >
> > Drivers don't need to set last_rx any more.
>
> Also, a NAPI driver should call netif_receive_skb() instead of
> netif_rx()
>
> netif_rx() is more expensive because of additional queue, while
> netif_receive_skb() directly calls the upper stacks.

Yes, but not until the poll function is changed to enable IRQs.

Ben.

--
Ben Hutchings, Staff Engineer, Solarflare
Not speaking for my employer; that's the marketing department's job.
They asked us to note that Solarflare product names are trademarked.



\
 
 \ /
  Last update: 2012-03-06 02:29    [W:0.077 / U:0.068 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site