diff options
author | Arnaldo Carvalho de Melo <acme@redhat.com> | 2007-04-11 00:04:22 -0400 |
---|---|---|
committer | David S. Miller <davem@sunset.davemloft.net> | 2007-04-26 01:25:26 -0400 |
commit | aa8223c7bb0b05183e1737881ed21827aa5b9e73 (patch) | |
tree | 05c9832326edfeb878472f15cf8133ed9f014cdf /drivers/net/e1000/e1000_main.c | |
parent | ab6a5bb6b28a970104a34f0f6959b73cf61bdc72 (diff) |
[SK_BUFF]: Introduce tcp_hdr(), remove skb->h.th
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/e1000/e1000_main.c')
-rw-r--r-- | drivers/net/e1000/e1000_main.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/drivers/net/e1000/e1000_main.c b/drivers/net/e1000/e1000_main.c index 4572fbba50f9..e86deb2ef823 100644 --- a/drivers/net/e1000/e1000_main.c +++ b/drivers/net/e1000/e1000_main.c | |||
@@ -2893,14 +2893,15 @@ e1000_tso(struct e1000_adapter *adapter, struct e1000_tx_ring *tx_ring, | |||
2893 | struct iphdr *iph = ip_hdr(skb); | 2893 | struct iphdr *iph = ip_hdr(skb); |
2894 | iph->tot_len = 0; | 2894 | iph->tot_len = 0; |
2895 | iph->check = 0; | 2895 | iph->check = 0; |
2896 | skb->h.th->check = ~csum_tcpudp_magic(iph->saddr, | 2896 | tcp_hdr(skb)->check = ~csum_tcpudp_magic(iph->saddr, |
2897 | iph->daddr, 0, | 2897 | iph->daddr, 0, |
2898 | IPPROTO_TCP, 0); | 2898 | IPPROTO_TCP, |
2899 | 0); | ||
2899 | cmd_length = E1000_TXD_CMD_IP; | 2900 | cmd_length = E1000_TXD_CMD_IP; |
2900 | ipcse = skb_transport_offset(skb) - 1; | 2901 | ipcse = skb_transport_offset(skb) - 1; |
2901 | } else if (skb->protocol == htons(ETH_P_IPV6)) { | 2902 | } else if (skb->protocol == htons(ETH_P_IPV6)) { |
2902 | ipv6_hdr(skb)->payload_len = 0; | 2903 | ipv6_hdr(skb)->payload_len = 0; |
2903 | skb->h.th->check = | 2904 | tcp_hdr(skb)->check = |
2904 | ~csum_ipv6_magic(&ipv6_hdr(skb)->saddr, | 2905 | ~csum_ipv6_magic(&ipv6_hdr(skb)->saddr, |
2905 | &ipv6_hdr(skb)->daddr, | 2906 | &ipv6_hdr(skb)->daddr, |
2906 | 0, IPPROTO_TCP, 0); | 2907 | 0, IPPROTO_TCP, 0); |
@@ -2909,7 +2910,7 @@ e1000_tso(struct e1000_adapter *adapter, struct e1000_tx_ring *tx_ring, | |||
2909 | ipcss = skb_network_offset(skb); | 2910 | ipcss = skb_network_offset(skb); |
2910 | ipcso = (void *)&(ip_hdr(skb)->check) - (void *)skb->data; | 2911 | ipcso = (void *)&(ip_hdr(skb)->check) - (void *)skb->data; |
2911 | tucss = skb_transport_offset(skb); | 2912 | tucss = skb_transport_offset(skb); |
2912 | tucso = (void *)&(skb->h.th->check) - (void *)skb->data; | 2913 | tucso = (void *)&(tcp_hdr(skb)->check) - (void *)skb->data; |
2913 | tucse = 0; | 2914 | tucse = 0; |
2914 | 2915 | ||
2915 | cmd_length |= (E1000_TXD_CMD_DEXT | E1000_TXD_CMD_TSE | | 2916 | cmd_length |= (E1000_TXD_CMD_DEXT | E1000_TXD_CMD_TSE | |