From: Simon Horman <horms@kernel.org>
To: Eric Dumazet <edumazet@google.com>
Cc: "David S . Miller" <davem@davemloft.net>,
Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
netdev@vger.kernel.org, David Ahern <dsahern@kernel.org>,
Kuniyuki Iwashima <kuniyu@amazon.com>,
eric.dumazet@gmail.com
Subject: Re: [PATCH net-next 2/4] inetpeer: remove create argument of inet_getpeer()
Date: Fri, 13 Dec 2024 20:16:41 +0000 [thread overview]
Message-ID: <20241213201641.GH561418@kernel.org> (raw)
In-Reply-To: <20241213130212.1783302-3-edumazet@google.com>
On Fri, Dec 13, 2024 at 01:02:10PM +0000, Eric Dumazet wrote:
> All callers of inet_getpeer() want to create an inetpeer.
>
> Signed-off-by: Eric Dumazet <edumazet@google.com>
...
> diff --git a/net/ipv4/inetpeer.c b/net/ipv4/inetpeer.c
...
> @@ -189,10 +188,6 @@ struct inet_peer *inet_getpeer(struct inet_peer_base *base,
> if (p)
> return p;
>
> - /* If no writer did a change during our lookup, we can return early. */
> - if (!create && !invalidated)
> - return NULL;
> -
Hi Eric,
With this change invalidated is set but otherwise unused in this function,
so it can probably be removed.
Flagged by W=1 builds.
> /* retry an exact lookup, taking the lock before.
> * At least, nodes should be hot in our cache.
> */
next prev parent reply other threads:[~2024-12-13 20:16 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-12-13 13:02 [PATCH net-next 0/4] inetpeer: reduce false sharing and atomic operations Eric Dumazet
2024-12-13 13:02 ` [PATCH net-next 1/4] inetpeer: remove create argument of inet_getpeer_v[46]() Eric Dumazet
2024-12-13 13:02 ` [PATCH net-next 2/4] inetpeer: remove create argument of inet_getpeer() Eric Dumazet
2024-12-13 20:16 ` Simon Horman [this message]
2024-12-13 20:47 ` Eric Dumazet
2024-12-14 14:34 ` kernel test robot
2024-12-13 13:02 ` [PATCH net-next 3/4] inetpeer: update inetpeer timestamp in inet_getpeer() Eric Dumazet
2024-12-15 15:34 ` Ido Schimmel
2024-12-13 13:02 ` [PATCH net-next 4/4] inetpeer: do not get a refcount " Eric Dumazet
2024-12-15 15:48 ` Ido Schimmel
2024-12-15 17:42 ` Eric Dumazet
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=20241213201641.GH561418@kernel.org \
--to=horms@kernel.org \
--cc=davem@davemloft.net \
--cc=dsahern@kernel.org \
--cc=edumazet@google.com \
--cc=eric.dumazet@gmail.com \
--cc=kuba@kernel.org \
--cc=kuniyu@amazon.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.