aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorHerbert Xu <herbert@gondor.apana.org.au>2008-10-09 15:03:17 -0400
committerDavid S. Miller <davem@davemloft.net>2008-10-09 15:03:17 -0400
commit64194c31a0b6f5d84703b772113aafc400eeaad6 (patch)
tree68ade9b285112f8430ba29772f8318f0cb0553ed /include
parente1a8000228e16212c93b23cfbed4d622e2ec7a6b (diff)
inet: Make tunnel RX/TX byte counters more consistent
This patch makes the RX/TX byte counters for IPIP, GRE and SIT more consistent. Previously we included the external IP headers on the way out but not when the packet is inbound. The new scheme is to count payload only in both directions. For IPIP and SIT this simply means the exclusion of the external IP header. For GRE this means that we exclude the GRE header as well. Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include')
-rw-r--r--include/net/ipip.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/net/ipip.h b/include/net/ipip.h
index a85bda64b852..fdf9bd743705 100644
--- a/include/net/ipip.h
+++ b/include/net/ipip.h
@@ -37,7 +37,7 @@ struct ip_tunnel_prl_entry
37 37
38#define IPTUNNEL_XMIT() do { \ 38#define IPTUNNEL_XMIT() do { \
39 int err; \ 39 int err; \
40 int pkt_len = skb->len; \ 40 int pkt_len = skb->len - skb_transport_offset(skb); \
41 \ 41 \
42 skb->ip_summed = CHECKSUM_NONE; \ 42 skb->ip_summed = CHECKSUM_NONE; \
43 ip_select_ident(iph, &rt->u.dst, NULL); \ 43 ip_select_ident(iph, &rt->u.dst, NULL); \