Thread (2 messages) flat view 2 messages, 2 authors, 1d ago
WARM1d

[PATCH net] ppp_synctty: remove redundant skb null check in ppp_sync_txmunge()

From: Qingfang Deng <hidden>
Date: 2026-09-20 11:50:04
Also in: lkml
Subsystem: networking drivers, ppp protocol drivers and compressors, the rest · Maintainers: Andrew Lunn, "David S. Miller", Eric Dumazet, Jakub Kicinski, Paolo Abeni, Linus Torvalds

The skb is already dereferenced before the check. In addition, a TX skb
passed from the generic layer can never be null.

Remove the redundant null check.

Fixes: 1da177e4c3f4 ("Linux-2.6.12-rc2")
Reported-by: kernel test robot <redacted>
Reported-by: Dan Carpenter <redacted>
Closes: https://lore.kernel.org/r/202609132245.txZXoUxc-lkp@intel.com/ (local)
Signed-off-by: Qingfang Deng <redacted>
---
 drivers/net/ppp/ppp_synctty.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/ppp/ppp_synctty.c b/drivers/net/ppp/ppp_synctty.c
index 9e440e110e9f..b90ae0583c84 100644
--- a/drivers/net/ppp/ppp_synctty.c
+++ b/drivers/net/ppp/ppp_synctty.c
@@ -464,7 +464,7 @@ ppp_sync_txmunge(struct syncppp *ap, struct sk_buff *skb)
 
 	ap->last_xmit = jiffies;
 
-	if (skb && ap->flags & SC_LOG_OUTPKT)
+	if (ap->flags & SC_LOG_OUTPKT)
 		ppp_print_buffer ("send buffer", skb->data, skb->len);
 
 	return skb;
-- 
2.34.1
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help