tipc: eliminate redundant code with kfree_skb_list routine
sk_buff lists are currently relased by looping over the list and explicitly releasing each buffer. We replace all occurrences of this loop with a call to kfree_skb_list(). Signed-off-by: Ying Xue <ying.xue@windriver.com> Reviewed-by: Paul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: Jon Maloy <jon.maloy@ericsson.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:

committed by
David S. Miller

parent
4ba3f99a36
commit
d77b3831f7
@@ -291,11 +291,7 @@ static void node_lost_contact(struct tipc_node *n_ptr)
|
||||
|
||||
/* Flush broadcast link info associated with lost node */
|
||||
if (n_ptr->bclink.recv_permitted) {
|
||||
while (n_ptr->bclink.deferred_head) {
|
||||
struct sk_buff *buf = n_ptr->bclink.deferred_head;
|
||||
n_ptr->bclink.deferred_head = buf->next;
|
||||
kfree_skb(buf);
|
||||
}
|
||||
kfree_skb_list(n_ptr->bclink.deferred_head);
|
||||
n_ptr->bclink.deferred_size = 0;
|
||||
|
||||
if (n_ptr->bclink.reasm_head) {
|
||||
|
Reference in New Issue
Block a user