From d280d78b3ff670744053b5dc4af67e5fd74b972b Mon Sep 17 00:00:00 2001 From: Subash Abhinov Kasiviswanathan Date: Tue, 22 Sep 2020 10:16:30 +0800 Subject: [PATCH] dev: Defer free of skbs in flush_backlog stable inclusion from linux-4.19.136 commit 68c46a0adc6f0409946b6da6a903241ec7dbf5cd -------------------------------- [ Upstream commit 7df5cb75cfb8acf96c7f2342530eb41e0c11f4c3 ] IRQs are disabled when freeing skbs in input queue. Use the IRQ safe variant to free skbs here. Fixes: 145dd5f9c88f ("net: flush the softnet backlog in process context") Signed-off-by: Subash Abhinov Kasiviswanathan Signed-off-by: David S. Miller Signed-off-by: Greg Kroah-Hartman Signed-off-by: Yang Yingliang Signed-off-by: Li Aichun Reviewed-by: guodeqing Signed-off-by: Yang Yingliang --- net/core/dev.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/net/core/dev.c b/net/core/dev.c index 4b1053057ca6..42ba150fa18d 100644 --- a/net/core/dev.c +++ b/net/core/dev.c @@ -5252,7 +5252,7 @@ static void flush_backlog(struct work_struct *work) skb_queue_walk_safe(&sd->input_pkt_queue, skb, tmp) { if (skb->dev->reg_state == NETREG_UNREGISTERING) { __skb_unlink(skb, &sd->input_pkt_queue); - kfree_skb(skb); + dev_kfree_skb_irq(skb); input_queue_head_incr(sd); } } -- GitLab