From: Murari Prasad Samal <murariprasadsamal57@gmail.com>
To: netdev@vger.kernel.org
Cc: andrew+netdev@lunn.ch, davem@davemloft.net, edumazet@google.com,
kuba@kernel.org, pabeni@redhat.com,
Murari Prasad Samal <murariprasadsamal57@gmail.com>
Subject: [PATCH v3] net: ifb: record drop reason when redirect device is missing
Date: Tue, 3 Feb 2026 06:09:07 +0000 [thread overview]
Message-ID: <20260203060907.993-1-murariprasadsamal57@gmail.com> (raw)
In-Reply-To: <20260202191135.7668-1-murariprasadsamal57@gmail.com>
When redirecting packets in ifb_ri_tasklet(), the skb is dropped
if the original ingress device can no longer be found.
Use kfree_skb_reason() with SKB_DROP_REASON_DEV_DOWN so the drop
is properly attributed.
No functional change intended.
Signed-off-by: Murari Prasad Samal
---
drivers/net/ifb.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/ifb.c b/drivers/net/ifb.c
index d3dc0914450a..689340ccf9c7 100644
--- a/drivers/net/ifb.c
+++ b/drivers/net/ifb.c
@@ -115,7 +115,7 @@ static void ifb_ri_tasklet(struct tasklet_struct *t)
skb->dev = dev_get_by_index_rcu(dev_net(txp->dev), skb->skb_iif);
if (!skb->dev) {
rcu_read_unlock();
- dev_kfree_skb(skb);
+ kfree_skb_reason(skb, SKB_DROP_REASON_NO_DEV);
txp->dev->stats.tx_dropped++;
if (skb_queue_len(&txp->tq) != 0)
goto resched;
--
2.43.0
next prev parent reply other threads:[~2026-02-03 6:09 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-02-02 19:11 [PATCH] net: ifb: record drop reason when redirect device is missing Murari Prasad Samal
2026-02-03 5:50 ` kernel test robot
2026-02-03 6:04 ` [PATCH v2] " Murari Prasad Samal
2026-02-03 6:09 ` Murari Prasad Samal [this message]
2026-02-03 11:33 ` [PATCH] " kernel test robot
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260203060907.993-1-murariprasadsamal57@gmail.com \
--to=murariprasadsamal57@gmail.com \
--cc=andrew+netdev@lunn.ch \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=kuba@kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox