projects
/
linux-2.6-block.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
63fbdd3
)
net: use DEBUG_NET_WARN_ON_ONCE() in dev_loopback_xmit()
author
Eric Dumazet
<edumazet@google.com>
Wed, 8 Jun 2022 16:04:32 +0000
(09:04 -0700)
committer
Jakub Kicinski
<kuba@kernel.org>
Fri, 10 Jun 2022 04:53:55 +0000
(21:53 -0700)
One check in dev_loopback_xmit() has not caught issues
in the past.
Keep it for CONFIG_DEBUG_NET=y builds only.
Signed-off-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
net/core/dev.c
patch
|
blob
|
blame
|
history
diff --git
a/net/core/dev.c
b/net/core/dev.c
index 511cf5d3aade63b708d97a00a09db27ef2e47765..39cb9055da37e47583fc553f1e16750acbe4ee37 100644
(file)
--- a/
net/core/dev.c
+++ b/
net/core/dev.c
@@
-3925,7
+3925,7
@@
int dev_loopback_xmit(struct net *net, struct sock *sk, struct sk_buff *skb)
skb->pkt_type = PACKET_LOOPBACK;
if (skb->ip_summed == CHECKSUM_NONE)
skb->ip_summed = CHECKSUM_UNNECESSARY;
-
WARN_ON
(!skb_dst(skb));
+
DEBUG_NET_WARN_ON_ONCE
(!skb_dst(skb));
skb_dst_force(skb);
netif_rx(skb);
return 0;