diff options
author | Herbert Xu <herbert@gondor.apana.org.au> | 2005-12-14 15:55:24 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2005-12-14 15:55:24 -0500 |
commit | 1542272a60ab9c0655a13ead8b7d7a661365f9fb (patch) | |
tree | 1a40dc0dec4f538471000c5b9031ce373ac26e2d /net/ipv4/ip_gre.c | |
parent | acd9b7b4e08a3f0f48afa922d8e371414cf2d3b2 (diff) |
[GRE]: Fix hardware checksum modification
The skb_postpull_rcsum introduced a bug to the checksum modification.
Although the length pulled is offset bytes, the origin of the pulling
is the GRE header, not the IP header.
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/ip_gre.c')
-rw-r--r-- | net/ipv4/ip_gre.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/net/ipv4/ip_gre.c b/net/ipv4/ip_gre.c index a4c347c3b8e3..46f9d9cf7a5f 100644 --- a/net/ipv4/ip_gre.c +++ b/net/ipv4/ip_gre.c | |||
@@ -618,7 +618,7 @@ static int ipgre_rcv(struct sk_buff *skb) | |||
618 | 618 | ||
619 | skb->mac.raw = skb->nh.raw; | 619 | skb->mac.raw = skb->nh.raw; |
620 | skb->nh.raw = __pskb_pull(skb, offset); | 620 | skb->nh.raw = __pskb_pull(skb, offset); |
621 | skb_postpull_rcsum(skb, skb->mac.raw, offset); | 621 | skb_postpull_rcsum(skb, skb->h.raw, offset); |
622 | memset(&(IPCB(skb)->opt), 0, sizeof(struct ip_options)); | 622 | memset(&(IPCB(skb)->opt), 0, sizeof(struct ip_options)); |
623 | skb->pkt_type = PACKET_HOST; | 623 | skb->pkt_type = PACKET_HOST; |
624 | #ifdef CONFIG_NET_IPGRE_BROADCAST | 624 | #ifdef CONFIG_NET_IPGRE_BROADCAST |