Commit 6636fb31 authored by Hayes Wang's avatar Hayes Wang Committed by David S. Miller

r8152: fix accessing skb after napi_gro_receive

Fix accessing skb after napi_gro_receive which is caused by
commit 47922fcd ("r8152: support skb_add_rx_frag").

Fixes: 47922fcd ("r8152: support skb_add_rx_frag")
Signed-off-by: default avatarHayes Wang <hayeswang@realtek.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 44b3769b
......@@ -2094,10 +2094,10 @@ static int rx_bottom(struct r8152 *tp, int budget)
skb->protocol = eth_type_trans(skb, netdev);
rtl_rx_vlan_tag(rx_desc, skb);
if (work_done < budget) {
napi_gro_receive(napi, skb);
work_done++;
stats->rx_packets++;
stats->rx_bytes += skb->len;
napi_gro_receive(napi, skb);
} else {
__skb_queue_tail(&tp->rx_queue, skb);
}
......
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