]> git.karo-electronics.de Git - linux-beck.git/commit
tg3: provide frags as skb head
authorEric Dumazet <edumazet@google.com>
Fri, 27 Apr 2012 00:34:49 +0000 (00:34 +0000)
committerDavid S. Miller <davem@davemloft.net>
Tue, 1 May 2012 01:35:42 +0000 (21:35 -0400)
commit8d4057a938481351dc690fbe23e8c72af08d5890
tree87736275c117327f55e381c88dba1ec1e067e4c0
parentd3836f21b0af5513ef55701dd3f50b8c42e44c7a
tg3: provide frags as skb head

This patch converts tg3 driver, one of our reference drivers, to use new
build_skb() api in frag mode.

Instead of using kmalloc() to allocate the memory block that will be
used by build_skb() as skb->head, we use a page fragment.

This is a followup of patch "net: allow skb->head to be a page fragment"

This allows GRO, TCP coalescing, and splice() to be more efficient.

Incidentally, this also removes SLUB slow path contention in kfree()

Signed-off-by: Eric Dumazet <edumazet@google.com>
Cc: Ilpo Järvinen <ilpo.jarvinen@helsinki.fi>
Cc: Herbert Xu <herbert@gondor.apana.org.au>
Cc: Maciej Żenczykowski <maze@google.com>
Cc: Neal Cardwell <ncardwell@google.com>
Cc: Tom Herbert <therbert@google.com>
Cc: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Cc: Ben Hutchings <bhutchings@solarflare.com>
Cc: Matt Carlson <mcarlson@broadcom.com>
Cc: Michael Chan <mchan@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/broadcom/tg3.c
drivers/net/ethernet/broadcom/tg3.h