netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v1 net-next] tcp: Don't reinitialise tw->tw_transparent in tcp_time_wait().
@ 2025-11-18  0:04 Kuniyuki Iwashima
  2025-11-18  0:11 ` Jason Xing
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Kuniyuki Iwashima @ 2025-11-18  0:04 UTC (permalink / raw)
  To: David S. Miller, Eric Dumazet, Jakub Kicinski, Paolo Abeni,
	Neal Cardwell
  Cc: Simon Horman, Kuniyuki Iwashima, Kuniyuki Iwashima, netdev

tw->tw_transparent is initialised twice in inet_twsk_alloc()
and tcp_time_wait().

Let's remove the latter.

Signed-off-by: Kuniyuki Iwashima <kuniyu@google.com>
---
 net/ipv4/tcp_minisocks.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/net/ipv4/tcp_minisocks.c b/net/ipv4/tcp_minisocks.c
index d8f4d813e8dd..bd5462154f97 100644
--- a/net/ipv4/tcp_minisocks.c
+++ b/net/ipv4/tcp_minisocks.c
@@ -337,7 +337,6 @@ void tcp_time_wait(struct sock *sk, int state, int timeo)
 		struct tcp_timewait_sock *tcptw = tcp_twsk((struct sock *)tw);
 		const int rto = (icsk->icsk_rto << 2) - (icsk->icsk_rto >> 1);
 
-		tw->tw_transparent	= inet_test_bit(TRANSPARENT, sk);
 		tw->tw_mark		= sk->sk_mark;
 		tw->tw_priority		= READ_ONCE(sk->sk_priority);
 		tw->tw_rcv_wscale	= tp->rx_opt.rcv_wscale;
-- 
2.52.0.rc1.455.g30608eb744-goog


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH v1 net-next] tcp: Don't reinitialise tw->tw_transparent in tcp_time_wait().
  2025-11-18  0:04 [PATCH v1 net-next] tcp: Don't reinitialise tw->tw_transparent in tcp_time_wait() Kuniyuki Iwashima
@ 2025-11-18  0:11 ` Jason Xing
  2025-11-19  2:03 ` Jakub Kicinski
  2025-11-19  2:10 ` patchwork-bot+netdevbpf
  2 siblings, 0 replies; 4+ messages in thread
From: Jason Xing @ 2025-11-18  0:11 UTC (permalink / raw)
  To: Kuniyuki Iwashima
  Cc: David S. Miller, Eric Dumazet, Jakub Kicinski, Paolo Abeni,
	Neal Cardwell, Simon Horman, Kuniyuki Iwashima, netdev

On Tue, Nov 18, 2025 at 8:05 AM Kuniyuki Iwashima <kuniyu@google.com> wrote:
>
> tw->tw_transparent is initialised twice in inet_twsk_alloc()
> and tcp_time_wait().
>
> Let's remove the latter.
>
> Signed-off-by: Kuniyuki Iwashima <kuniyu@google.com>

Reviewed-by: Jason Xing <kerneljasonxing@gmail.com>

Thanks,
Jason

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH v1 net-next] tcp: Don't reinitialise tw->tw_transparent in tcp_time_wait().
  2025-11-18  0:04 [PATCH v1 net-next] tcp: Don't reinitialise tw->tw_transparent in tcp_time_wait() Kuniyuki Iwashima
  2025-11-18  0:11 ` Jason Xing
@ 2025-11-19  2:03 ` Jakub Kicinski
  2025-11-19  2:10 ` patchwork-bot+netdevbpf
  2 siblings, 0 replies; 4+ messages in thread
From: Jakub Kicinski @ 2025-11-19  2:03 UTC (permalink / raw)
  To: Kuniyuki Iwashima
  Cc: David S. Miller, Eric Dumazet, Paolo Abeni, Neal Cardwell,
	Simon Horman, Kuniyuki Iwashima, netdev

On Tue, 18 Nov 2025 00:04:40 +0000 Kuniyuki Iwashima wrote:
> tw->tw_transparent is initialised twice in inet_twsk_alloc()
> and tcp_time_wait().
> 
> Let's remove the latter.

Coincidentally looks like inet_twsk_alloc() can be static

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH v1 net-next] tcp: Don't reinitialise tw->tw_transparent in tcp_time_wait().
  2025-11-18  0:04 [PATCH v1 net-next] tcp: Don't reinitialise tw->tw_transparent in tcp_time_wait() Kuniyuki Iwashima
  2025-11-18  0:11 ` Jason Xing
  2025-11-19  2:03 ` Jakub Kicinski
@ 2025-11-19  2:10 ` patchwork-bot+netdevbpf
  2 siblings, 0 replies; 4+ messages in thread
From: patchwork-bot+netdevbpf @ 2025-11-19  2:10 UTC (permalink / raw)
  To: Kuniyuki Iwashima
  Cc: davem, edumazet, kuba, pabeni, ncardwell, horms, kuni1840, netdev

Hello:

This patch was applied to netdev/net-next.git (main)
by Jakub Kicinski <kuba@kernel.org>:

On Tue, 18 Nov 2025 00:04:40 +0000 you wrote:
> tw->tw_transparent is initialised twice in inet_twsk_alloc()
> and tcp_time_wait().
> 
> Let's remove the latter.
> 
> Signed-off-by: Kuniyuki Iwashima <kuniyu@google.com>
> 
> [...]

Here is the summary with links:
  - [v1,net-next] tcp: Don't reinitialise tw->tw_transparent in tcp_time_wait().
    https://git.kernel.org/netdev/net-next/c/932478bf9f6d

You are awesome, thank you!
-- 
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html



^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2025-11-19  2:11 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-11-18  0:04 [PATCH v1 net-next] tcp: Don't reinitialise tw->tw_transparent in tcp_time_wait() Kuniyuki Iwashima
2025-11-18  0:11 ` Jason Xing
2025-11-19  2:03 ` Jakub Kicinski
2025-11-19  2:10 ` patchwork-bot+netdevbpf

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).