summaryrefslogtreecommitdiffstats
path: root/drivers/net/ixgb
diff options
context:
space:
mode:
authorArnaldo Carvalho de Melo2007-03-19 01:43:48 +0100
committerDavid S. Miller2007-04-26 07:25:24 +0200
commitab6a5bb6b28a970104a34f0f6959b73cf61bdc72 (patch)
tree54cfa7d4fe00d0c28a60022b075afc0856d6fc2b /drivers/net/ixgb
parent[SK_BUFF]: Introduce icmp_hdr(), remove skb->h.icmph (diff)
downloadkernel-qcow2-linux-ab6a5bb6b28a970104a34f0f6959b73cf61bdc72.tar.gz
kernel-qcow2-linux-ab6a5bb6b28a970104a34f0f6959b73cf61bdc72.tar.xz
kernel-qcow2-linux-ab6a5bb6b28a970104a34f0f6959b73cf61bdc72.zip
[TCP]: Introduce tcp_hdrlen() and tcp_optlen()
The ip_hdrlen() buddy, created to reduce the number of skb->h.th-> uses and to avoid the longer, open coded equivalent. Ditched a no-op in bnx2 in the process. I wonder if we should have a BUG_ON(skb->h.th->doff < 5) in tcp_optlen()... Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ixgb')
-rw-r--r--drivers/net/ixgb/ixgb_main.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/ixgb/ixgb_main.c b/drivers/net/ixgb/ixgb_main.c
index ceea6e45792d..96550d681623 100644
--- a/drivers/net/ixgb/ixgb_main.c
+++ b/drivers/net/ixgb/ixgb_main.c
@@ -1190,7 +1190,7 @@ ixgb_tso(struct ixgb_adapter *adapter, struct sk_buff *skb)
return err;
}
- hdr_len = (skb_transport_offset(skb) + (skb->h.th->doff << 2));
+ hdr_len = skb_transport_offset(skb) + tcp_hdrlen(skb);
mss = skb_shinfo(skb)->gso_size;
iph = ip_hdr(skb);
iph->tot_len = 0;