mirror of
https://github.com/Fishwaldo/linux-bl808.git
synced 2025-06-17 20:25:19 +00:00
tipc: use generic SKB list APIs to manage deferred queue of link
Use standard SKB list APIs associated with struct sk_buff_head to manage link's deferred queue, simplifying relevant code. Signed-off-by: Ying Xue <ying.xue@windriver.com> Reviewed-by: Jon Maloy <jon.maloy@ericsson.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
58dc55f256
commit
bc6fecd409
5 changed files with 47 additions and 69 deletions
|
@ -116,6 +116,7 @@ struct tipc_node *tipc_node_create(u32 addr)
|
|||
INIT_LIST_HEAD(&n_ptr->publ_list);
|
||||
INIT_LIST_HEAD(&n_ptr->conn_sks);
|
||||
__skb_queue_head_init(&n_ptr->waiting_sks);
|
||||
__skb_queue_head_init(&n_ptr->bclink.deferred_queue);
|
||||
|
||||
hlist_add_head_rcu(&n_ptr->hash, &node_htable[tipc_hashfn(addr)]);
|
||||
|
||||
|
@ -381,8 +382,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) {
|
||||
kfree_skb_list(n_ptr->bclink.deferred_head);
|
||||
n_ptr->bclink.deferred_size = 0;
|
||||
__skb_queue_purge(&n_ptr->bclink.deferred_queue);
|
||||
|
||||
if (n_ptr->bclink.reasm_buf) {
|
||||
kfree_skb(n_ptr->bclink.reasm_buf);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue