[ofa-general] Re: [PATCH 03/10] RDMA/nes: Remove tx_free_list

Roland Dreier rdreier at cisco.com
Mon Nov 24 13:56:50 PST 2008


 > +static struct sk_buff *get_free_pkt(u32 pktsize)
 >  {
 > -	u32 hashkey = 0;
 > -
 > -	hashkey = loc_addr + rem_addr + loc_port + rem_port;
 > -	hashkey = (hashkey % NES_CM_HASHTABLE_SIZE);
 > -
 > -	return hashkey;
 > +		return dev_alloc_skb(pktsize);
 >  }

Given this, is there any reason to have get_free_pkt() at all?  Why not
just use dev_alloc_skb() directly?

 - R.



More information about the general mailing list