Commit 56cfe5d0 authored by Wang Chen's avatar Wang Chen Committed by Jeff Garzik

NETFRONT: Use __skb_queue_purge()

Use standard routine for queue purging.
Signed-off-by: default avatarWang Chen <wangchen@cn.fujitsu.com>
Signed-off-by: default avatarJeff Garzik <jgarzik@redhat.com>
parent 288369cc
...@@ -946,8 +946,7 @@ err: ...@@ -946,8 +946,7 @@ err:
work_done++; work_done++;
} }
while ((skb = __skb_dequeue(&errq))) __skb_queue_purge(&errq);
kfree_skb(skb);
work_done -= handle_incoming_queue(dev, &rxq); work_done -= handle_incoming_queue(dev, &rxq);
...@@ -1079,8 +1078,7 @@ static void xennet_release_rx_bufs(struct netfront_info *np) ...@@ -1079,8 +1078,7 @@ static void xennet_release_rx_bufs(struct netfront_info *np)
} }
} }
while ((skb = __skb_dequeue(&free_list)) != NULL) __skb_queue_purge(&free_list);
dev_kfree_skb(skb);
spin_unlock_bh(&np->rx_lock); spin_unlock_bh(&np->rx_lock);
} }
......
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