[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20121027182207.GA12858@electric-eye.fr.zoreil.com>
Date: Sat, 27 Oct 2012 20:22:07 +0200
From: Francois Romieu <romieu@...zoreil.com>
To: Javier Domingo <javierdo1@...il.com>
Cc: Eric Dumazet <eric.dumazet@...il.com>, netdev@...r.kernel.org
Subject: Re: Information about napi_struct and net_device
Eric Dumazet <eric.dumazet@...il.com> :
[...]
> # grep -n napi drivers/net/ethernet/realtek/8139cp.c
> 327: struct napi_struct napi;
> 436: napi_gro_receive(&cp->napi, skb);
> 468:static int cp_rx_poll(struct napi_struct *napi, int budget)
> 470: struct cp_private *cp = container_of(napi, struct cp_private, napi);
> 566: napi_gro_flush(napi, false);
> 568: __napi_complete(napi);
> 605: if (napi_schedule_prep(&cp->napi)) {
> 607: __napi_schedule(&cp->napi);
> 1132: napi_enable(&cp->napi);
> 1149: napi_disable(&cp->napi);
> 1160: napi_disable(&cp->napi);
> 1933: netif_napi_add(dev, &cp->napi, cp_rx_poll, 16);
Not all drivers use napi_gro_receive/napi_gro_flush.
It could be worth comparing with drivers/net/ethernet/via/via-rhine.c (small)
or drivers/net/ethernet/broadcom/tg3.c (bigger).
--
Ueimor
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists