net: __pskb_pull_tail() & pskb_carve_frag_list() drop_monitor friends
Subsystems (2)
PATCH 1/1 net: __pskb_pull_tail() & pskb_carve_frag_list() drop_monitor friends
From: Eric Dumazet <[email protected]>
Whenever one of these functions pull all data from an skb in a frag_list, use consume_skb() instead of kfree_skb() to avoid polluting drop monitoring.
Fixes 6fa01ccd8830 ("skbuff: Add pskb_extract() helper function")
Signed-off-by Eric Dumazet <[email protected]>
--- net/core/skbuff.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
net/core/skbuff.c +2 -2
@@ -2276,7 +2276,7 @@ void *__pskb_pull_tail(struct sk_buff *skb, int delta)/* Free pulled out fragments. */ while ((list =skb_shinfo (skb)->frag_list) != insp) {skb_shinfo (skb)->frag_list = list->next; -kfree_skb (list); +consume_skb (list); }/* And insert new clone at head. */ if (clone) {
@@ -6105,7 +6105,7 @@ static int pskb_carve_frag_list(struct sk_buff *skb,/* Free pulled out fragments. */ while ((list = shinfo->frag_list) != insp) { shinfo->frag_list = list->next; -kfree_skb (list); +consume_skb (list); }/* And insert new clone at head. */ if (clone) {
Signature · 1 line
2.35.1.473.g83b2b277ed-goog
This patch was applied to netdev/net.git (master) by Jakub Kicinski <[email protected]>:
Hello:
This patch was applied to netdev/net.git (master)
by Jakub Kicinski <[email protected]>:
Quoted 10 lines · On Sun, 20 Feb 2022 07:40:52 -0800 you wrote:
From: Eric Dumazet <[email protected]>
Whenever one of these functions pull all data from an skb in a
frag_list, useconsume_skb()instead ofkfree_skb()to avoid polluting drop monitoring.Fixes 6fa01ccd8830 ("skbuff: Add pskb_extract() helper function")Signed-off-by Eric Dumazet <[email protected]>[...]
Here is the summary with links:
- [net] net: __pskb_pull_tail() & pskb_carve_frag_list() drop_monitor friends
https://git.kernel.org/netdev/net/c/ef527f968ae0
You are awesome, thank you!
Signature · 2 lines
Deet-doot-dot, I am a bot. https://korg.docs.kernel.org/patchwork/pwbot.html