ipv6: Correct comparisons and calculations using skb->tail and skb-transport_header
authorSimon Horman <horms@verge.net.au>
Tue, 28 May 2013 20:34:26 +0000 (20:34 +0000)
committerDavid S. Miller <davem@davemloft.net>
Wed, 29 May 2013 06:49:07 +0000 (23:49 -0700)
commit29a3cad5c6ae9e7fbf1509d01d39c3c3c38f11f9
treefd6436d8a820801843ca257807c8af0f36425291
parentced14f6804a979d1972415bc23f2f8ddb18595dd
ipv6: Correct comparisons and calculations using skb->tail and skb-transport_header

This corrects an regression introduced by "net: Use 16bits for *_headers
fields of struct skbuff" when NET_SKBUFF_DATA_USES_OFFSET is not set. In
that case skb->tail will be a pointer whereas skb->transport_header
will be an offset from head. This is corrected by using wrappers that
ensure that comparisons and calculations are always made using pointers.

Signed-off-by: Simon Horman <horms@verge.net.au>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv6/exthdrs_core.c
net/ipv6/icmp.c
net/ipv6/mcast.c
net/ipv6/mip6.c
net/ipv6/ndisc.c
net/ipv6/output_core.c
net/ipv6/raw.c
net/ipv6/route.c