All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jakub Sitnicki <jakub@cloudflare.com>
To: Eric Dumazet <edumazet@google.com>
Cc: netdev@vger.kernel.org, "David S. Miller" <davem@davemloft.net>,
	Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
	Kuniyuki Iwashima <kuniyu@amazon.com>,
	kernel-team@cloudflare.com,
	Marek Majkowski <marek@cloudflare.com>
Subject: Re: [PATCH net-next v2 1/2] inet: Add IP_LOCAL_PORT_RANGE socket option
Date: Tue, 10 Jan 2023 22:36:33 +0100	[thread overview]
Message-ID: <871qo2dq8z.fsf@cloudflare.com> (raw)
In-Reply-To: <CANn89iJmmENm6DTP4qjkN23j_KT7ZS_hweR5qks4VETsUzA_eQ@mail.gmail.com>

On Tue, Jan 10, 2023 at 03:28 PM +01, Eric Dumazet wrote:
> On Tue, Jan 10, 2023 at 2:37 PM Jakub Sitnicki <jakub@cloudflare.com> wrote:
>>
>> Users who want to share a single public IP address for outgoing connections
>> between several hosts traditionally reach for SNAT. However, SNAT requires
>> state keeping on the node(s) performing the NAT.
>>
>
>> v1 -> v2:
>>  * Fix the corner case when the per-socket range doesn't overlap with the
>>    per-netns range. Fallback correctly to the per-netns range. (Kuniyuki)
>>
>> Reviewed-by: Marek Majkowski <marek@cloudflare.com>
>> Signed-off-by: Jakub Sitnicki <jakub@cloudflare.com>
>> ---
>>  include/net/inet_sock.h         |  4 ++++
>>  include/net/ip.h                |  3 ++-
>>  include/uapi/linux/in.h         |  1 +
>>  net/ipv4/inet_connection_sock.c | 25 +++++++++++++++++++++++--
>>  net/ipv4/inet_hashtables.c      |  2 +-
>>  net/ipv4/ip_sockglue.c          | 18 ++++++++++++++++++
>>  net/ipv4/udp.c                  |  2 +-
>>  7 files changed, 50 insertions(+), 5 deletions(-)
>
>
> Being an INET option, I think net/sctp/socket.c should also be changed.

Will do. Should be a one-liner + test coverage.

> Not clear if selinux_socket_bind() needs any change, I would CC
> SELINUX maintainers for advice.

I will start a thread.

Thank you for taking a look.

  reply	other threads:[~2023-01-10 21:38 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-01-10 13:37 [PATCH net-next v2 0/2] Add IP_LOCAL_PORT_RANGE socket option Jakub Sitnicki
2023-01-10 13:37 ` [PATCH net-next v2 1/2] inet: " Jakub Sitnicki
2023-01-10 14:28   ` Eric Dumazet
2023-01-10 21:36     ` Jakub Sitnicki [this message]
2023-01-11  0:59   ` Kuniyuki Iwashima
2023-01-11 12:44     ` Jakub Sitnicki
2023-01-10 13:37 ` [PATCH net-next v2 2/2] selftests/net: Cover the " Jakub Sitnicki
2023-01-11  1:25   ` Kuniyuki Iwashima
2023-01-11 12:45     ` Jakub Sitnicki

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=871qo2dq8z.fsf@cloudflare.com \
    --to=jakub@cloudflare.com \
    --cc=davem@davemloft.net \
    --cc=edumazet@google.com \
    --cc=kernel-team@cloudflare.com \
    --cc=kuba@kernel.org \
    --cc=kuniyu@amazon.com \
    --cc=marek@cloudflare.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.