[SK_BUFF]: Introduce ip_hdr(), remove skb->nh.iph
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
committed by
David S. Miller
parent
e023dd6437
commit
eddc9ec53b
@@ -806,7 +806,7 @@ static int cp_start_xmit (struct sk_buff *skb, struct net_device *dev)
|
||||
if (mss)
|
||||
flags |= LargeSend | ((mss & MSSMask) << MSSShift);
|
||||
else if (skb->ip_summed == CHECKSUM_PARTIAL) {
|
||||
const struct iphdr *ip = skb->nh.iph;
|
||||
const struct iphdr *ip = ip_hdr(skb);
|
||||
if (ip->protocol == IPPROTO_TCP)
|
||||
flags |= IPCS | TCPCS;
|
||||
else if (ip->protocol == IPPROTO_UDP)
|
||||
@@ -825,7 +825,7 @@ static int cp_start_xmit (struct sk_buff *skb, struct net_device *dev)
|
||||
u32 first_len, first_eor;
|
||||
dma_addr_t first_mapping;
|
||||
int frag, first_entry = entry;
|
||||
const struct iphdr *ip = skb->nh.iph;
|
||||
const struct iphdr *ip = ip_hdr(skb);
|
||||
|
||||
/* We must give this initial chunk to the device last.
|
||||
* Otherwise we could race with the device.
|
||||
|
Reference in New Issue
Block a user