[ofa-general] Re: [PATCH 2/10 REV5] [core] Add skb_blist & support for batching
Evgeniy Polyakov
johnpol at 2ka.mipt.ru
Fri Sep 14 05:46:38 PDT 2007
On Fri, Sep 14, 2007 at 02:31:37PM +0530, Krishna Kumar (krkumar2 at in.ibm.com) wrote:
> @@ -3566,6 +3579,13 @@ int register_netdevice(struct net_device
> }
> }
>
> + if (dev->features & NETIF_F_BATCH_SKBS) {
> + /* Driver supports batching skb */
> + dev->skb_blist = kmalloc(sizeof *dev->skb_blist, GFP_KERNEL);
> + if (dev->skb_blist)
> + skb_queue_head_init(dev->skb_blist);
> + }
> +
A nitpick is that you should use sizeof(struct ...) and I think it
requires flag clearing in cae of failed initialization?
> /*
> * nil rebuild_header routine,
> * that should be never called and used as just bug trap.
--
Evgeniy Polyakov
More information about the general
mailing list