Commit efd9450e authored by Eric Dumazet's avatar Eric Dumazet Committed by David S. Miller

net: use skb_reset_mac_len() in dev_gro_receive()

We no longer need to use mac_len, lets cleanup things.
Signed-off-by: default avatarEric Dumazet <edumazet@google.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent c14dd268
...@@ -3802,7 +3802,6 @@ static enum gro_result dev_gro_receive(struct napi_struct *napi, struct sk_buff ...@@ -3802,7 +3802,6 @@ static enum gro_result dev_gro_receive(struct napi_struct *napi, struct sk_buff
__be16 type = skb->protocol; __be16 type = skb->protocol;
struct list_head *head = &offload_base; struct list_head *head = &offload_base;
int same_flow; int same_flow;
int mac_len;
enum gro_result ret; enum gro_result ret;
if (!(skb->dev->features & NETIF_F_GRO) || netpoll_rx_on(skb)) if (!(skb->dev->features & NETIF_F_GRO) || netpoll_rx_on(skb))
...@@ -3819,8 +3818,7 @@ static enum gro_result dev_gro_receive(struct napi_struct *napi, struct sk_buff ...@@ -3819,8 +3818,7 @@ static enum gro_result dev_gro_receive(struct napi_struct *napi, struct sk_buff
continue; continue;
skb_set_network_header(skb, skb_gro_offset(skb)); skb_set_network_header(skb, skb_gro_offset(skb));
mac_len = skb->network_header - skb->mac_header; skb_reset_mac_len(skb);
skb->mac_len = mac_len;
NAPI_GRO_CB(skb)->same_flow = 0; NAPI_GRO_CB(skb)->same_flow = 0;
NAPI_GRO_CB(skb)->flush = 0; NAPI_GRO_CB(skb)->flush = 0;
NAPI_GRO_CB(skb)->free = 0; NAPI_GRO_CB(skb)->free = 0;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment