diff options
author | Michał Mirosław <mirq-linux@rere.qmqm.pl> | 2010-12-14 16:24:08 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-12-16 23:43:14 +0100 |
commit | 55508d601dab7df5cbcc7a63f4be8620eface204 (patch) | |
tree | 346f30fae9c726d2e73aba2e37ce1e4a31dcea8c /drivers/net/tun.c | |
parent | net: Introduce skb_checksum_start_offset() (diff) | |
download | linux-55508d601dab7df5cbcc7a63f4be8620eface204.tar.xz linux-55508d601dab7df5cbcc7a63f4be8620eface204.zip |
net: Use skb_checksum_start_offset()
Replace skb->csum_start - skb_headroom(skb) with skb_checksum_start_offset().
Note for usb/smsc95xx: skb->data - skb->head == skb_headroom(skb).
Signed-off-by: Michał Mirosław <mirq-linux@rere.qmqm.pl>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/tun.c')
-rw-r--r-- | drivers/net/tun.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/tun.c b/drivers/net/tun.c index 55f3a3e667a9..7599c457abd1 100644 --- a/drivers/net/tun.c +++ b/drivers/net/tun.c @@ -757,7 +757,7 @@ static __inline__ ssize_t tun_put_user(struct tun_struct *tun, if (skb->ip_summed == CHECKSUM_PARTIAL) { gso.flags = VIRTIO_NET_HDR_F_NEEDS_CSUM; - gso.csum_start = skb->csum_start - skb_headroom(skb); + gso.csum_start = skb_checksum_start_offset(skb); gso.csum_offset = skb->csum_offset; } /* else everything is zero */ |