From: Willem de Bruijn <willemdebruijn.kernel@gmail.com>
To: Eric Dumazet <edumazet@google.com>,
"David S . Miller" <davem@davemloft.net>,
Jakub Kicinski <kuba@kernel.org>,
Paolo Abeni <pabeni@redhat.com>
Cc: Simon Horman <horms@kernel.org>,
Kuniyuki Iwashima <kuniyu@google.com>,
netdev@vger.kernel.org, eric.dumazet@gmail.com,
Eric Dumazet <edumazet@google.com>
Subject: Re: [PATCH net-next] net: fix off-by-one in udp_flow_src_port() / psp_write_headers()
Date: Mon, 02 Mar 2026 14:58:07 -0500 [thread overview]
Message-ID: <willemdebruijn.kernel.352024981d617@gmail.com> (raw)
In-Reply-To: <20260302163933.1754393-1-edumazet@google.com>
Eric Dumazet wrote:
> udp_flow_src_port() and psp_write_headers() use ip_local_port_range.
>
> ip_local_port_range is inclusive : all ports between min and max
> can be used.
>
> Before this patch, if ip_local_port_range was set to 40000-40001
> 40001 would not be used as a source port.
>
> Use reciprocal_scale() to help code readability.
>
> Not tagged for stable trees, as this change could break user
> expectations.
>
> Signed-off-by: Eric Dumazet <edumazet@google.com>
Reviewed-by: Willem de Bruijn <willemb@google.com>
next prev parent reply other threads:[~2026-03-02 19:58 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-02 16:39 [PATCH net-next] net: fix off-by-one in udp_flow_src_port() / psp_write_headers() Eric Dumazet
2026-03-02 19:58 ` Willem de Bruijn [this message]
2026-03-05 1:01 ` patchwork-bot+netdevbpf
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=willemdebruijn.kernel.352024981d617@gmail.com \
--to=willemdebruijn.kernel@gmail.com \
--cc=davem@davemloft.net \
--cc=edumazet@google.com \
--cc=eric.dumazet@gmail.com \
--cc=horms@kernel.org \
--cc=kuba@kernel.org \
--cc=kuniyu@google.com \
--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