From: Stephen Hemminger Date: Fri, 3 Feb 2006 00:53:26 +0000 (-0800) Subject: [NET] snap: needs hardware checksum fix X-Git-Tag: v2.6.16-rc3~210^2~10 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=42c5e15f18d63c1ecf79d52bdaf4ea31cd22416d;p=linux-2.6 [NET] snap: needs hardware checksum fix The SNAP code pops off it's 5 byte header, but doesn't adjust the checksum. This would cause problems when using device that does IP over SNAP and hardware receive checksums. Signed-off-by: Stephen Hemminger Signed-off-by: David S. Miller --- diff --git a/net/802/psnap.c b/net/802/psnap.c index 4d638944d9..34e42968b4 100644 --- a/net/802/psnap.c +++ b/net/802/psnap.c @@ -59,8 +59,10 @@ static int snap_rcv(struct sk_buff *skb, struct net_device *dev, proto = find_snap_client(skb->h.raw); if (proto) { /* Pass the frame on. */ + u8 *hdr = skb->data; skb->h.raw += 5; skb_pull(skb, 5); + skb_postpull_rcsum(skb, hdr, 5); rc = proto->rcvfunc(skb, dev, &snap_packet_type, orig_dev); } else { skb->sk = NULL;