Thread (16 messages) 16 messages, 2 authors, 2024-11-06

Re: [PATCH RESEND net-next v4 6/9] net: ip: make ip_route_input_noref() return drop reasons

From: Menglong Dong <hidden>
Date: 2024-11-06 09:39:09
Also in: bpf, bridge, lkml, netfilter-devel

On Tue, Nov 5, 2024 at 7:22 PM Paolo Abeni [off-list ref] wrote:
Hi,

On 10/30/24 02:41, Menglong Dong wrote:
quoted
@@ -175,10 +175,12 @@ static void ip_expire(struct timer_list *t)

      /* skb has no dst, perform route lookup again */
      iph = ip_hdr(head);
-     err = ip_route_input_noref(head, iph->daddr, iph->saddr, ip4h_dscp(iph),
-                                head->dev);
-     if (err)
+     reason = ip_route_input_noref(head, iph->daddr, iph->saddr,
+                                   ip4h_dscp(iph), head->dev);
+     if (reason)
              goto out;
+     else
+             reason = SKB_DROP_REASON_FRAG_REASM_TIMEOUT;
I think the else branch above is confusing - and unneeded.
Yeah, that makes sense.
Please move the assignment after the comment below, so it's clear why we
get a TIMEOUT drop reason.
Okay!

Thanks!
Menglong Dong
Thanks,

Paolo
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help