]> git.baikalelectronics.ru Git - kernel.git/commit
skb: Add inline helper for getting the skb end offset from head
authorAlexander Duyck <alexander.h.duyck@intel.com>
Fri, 4 May 2012 14:26:56 +0000 (14:26 +0000)
committerDavid S. Miller <davem@davemloft.net>
Sun, 6 May 2012 17:13:19 +0000 (13:13 -0400)
commita122c1156949f375e03803c8141d9fa48914695a
tree8b7890f23ad078d9eccbd4571e0b2da86b04a6a0
parent15c29c079f41aefe71c1ad36626994256a462cf1
skb: Add inline helper for getting the skb end offset from head

With the recent changes for how we compute the skb truesize it occurs to me
we are probably going to have a lot of calls to skb_end_pointer -
skb->head.  Instead of running all over the place doing that it would make
more sense to just make it a separate inline skb_end_offset(skb) that way
we can return the correct value without having gcc having to do all the
optimization to cancel out skb->head - skb->head.

Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com>
Acked-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/atm/ambassador.c
drivers/atm/idt77252.c
drivers/net/wimax/i2400m/usb-rx.c
drivers/staging/octeon/ethernet-tx.c
include/linux/skbuff.h
net/core/skbuff.c