aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/tg3.c
diff options
context:
space:
mode:
authorArnaldo Carvalho de Melo <acme@redhat.com>2007-04-11 00:04:22 -0400
committerDavid S. Miller <davem@sunset.davemloft.net>2007-04-26 01:25:26 -0400
commitaa8223c7bb0b05183e1737881ed21827aa5b9e73 (patch)
tree05c9832326edfeb878472f15cf8133ed9f014cdf /drivers/net/tg3.c
parentab6a5bb6b28a970104a34f0f6959b73cf61bdc72 (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/tg3.c')
-rw-r--r--drivers/net/tg3.c15
1 files changed, 7 insertions, 8 deletions
diff --git a/drivers/net/tg3.c b/drivers/net/tg3.c
index 7ca30d76bf6f..414365c3198d 100644
--- a/drivers/net/tg3.c
+++ b/drivers/net/tg3.c
@@ -3922,7 +3922,7 @@ static int tg3_start_xmit(struct sk_buff *skb, struct net_device *dev)
3922 base_flags |= (TXD_FLAG_CPU_PRE_DMA | 3922 base_flags |= (TXD_FLAG_CPU_PRE_DMA |
3923 TXD_FLAG_CPU_POST_DMA); 3923 TXD_FLAG_CPU_POST_DMA);
3924 3924
3925 skb->h.th->check = 0; 3925 tcp_hdr(skb)->check = 0;
3926 3926
3927 } 3927 }
3928 else if (skb->ip_summed == CHECKSUM_PARTIAL) 3928 else if (skb->ip_summed == CHECKSUM_PARTIAL)
@@ -4080,14 +4080,13 @@ static int tg3_start_xmit_dma_bug(struct sk_buff *skb, struct net_device *dev)
4080 iph->check = 0; 4080 iph->check = 0;
4081 iph->tot_len = htons(mss + hdr_len); 4081 iph->tot_len = htons(mss + hdr_len);
4082 if (tp->tg3_flags2 & TG3_FLG2_HW_TSO) { 4082 if (tp->tg3_flags2 & TG3_FLG2_HW_TSO) {
4083 skb->h.th->check = 0; 4083 tcp_hdr(skb)->check = 0;
4084 base_flags &= ~TXD_FLAG_TCPUDP_CSUM; 4084 base_flags &= ~TXD_FLAG_TCPUDP_CSUM;
4085 } 4085 } else
4086 else { 4086 tcp_hdr(skb)->check = ~csum_tcpudp_magic(iph->saddr,
4087 skb->h.th->check = ~csum_tcpudp_magic(iph->saddr, 4087 iph->daddr, 0,
4088 iph->daddr, 0, 4088 IPPROTO_TCP,
4089 IPPROTO_TCP, 0); 4089 0);
4090 }
4091 4090
4092 if ((tp->tg3_flags2 & TG3_FLG2_HW_TSO) || 4091 if ((tp->tg3_flags2 & TG3_FLG2_HW_TSO) ||
4093 (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5705)) { 4092 (GET_ASIC_REV(tp->pci_chip_rev_id) == ASIC_REV_5705)) {