* [PATCH net-next v2] tcp: remove unused hash_size from struct tcp_out_options
@ 2026-03-07 5:16 Keita Morisaki
2026-03-07 15:29 ` Eric Dumazet
2026-03-10 2:00 ` patchwork-bot+netdevbpf
0 siblings, 2 replies; 3+ messages in thread
From: Keita Morisaki @ 2026-03-07 5:16 UTC (permalink / raw)
To: edumazet, ncardwell, kuniyu, davem, dsahern, kuba, pabeni, horms
Cc: netdev, linux-kernel, jakub, Keita Morisaki
hash_size is declared but never read. The MD5 path always uses a
fixed size of 16, and the TCP-AO path uses tcp_ao_maclen().
This closes a 7-byte hole and reduces the struct size from 96 to
88 bytes.
Suggested-by: Jakub Sitnicki <jakub@cloudflare.com>
Signed-off-by: Keita Morisaki <kmta1236@gmail.com>
Reviewed-by: Kuniyuki Iwashima <kuniyu@google.com>
---
Changes in v2:
- Added struct size improvement details to commit message (Jakub)
- Added Reviewed-by tag
net/ipv4/tcp_output.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/net/ipv4/tcp_output.c b/net/ipv4/tcp_output.c
index f0ebcc7e2..4377b3673 100644
--- a/net/ipv4/tcp_output.c
+++ b/net/ipv4/tcp_output.c
@@ -441,7 +441,6 @@ struct tcp_out_options {
u8 ws; /* window scale, 0 to disable */
u8 num_accecn_fields:7, /* number of AccECN fields needed */
use_synack_ecn_bytes:1; /* Use synack_ecn_bytes or not */
- u8 hash_size; /* bytes in hash_location */
__u8 *hash_location; /* temporary pointer, overloaded */
__u32 tsval, tsecr; /* need to include OPTION_TS */
struct tcp_fastopen_cookie *fastopen_cookie; /* Fast open cookie */
base-commit: f4ac0cc88e9949d41bbdd101caa3117afe983ec9
--
2.53.0
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH net-next v2] tcp: remove unused hash_size from struct tcp_out_options
2026-03-07 5:16 [PATCH net-next v2] tcp: remove unused hash_size from struct tcp_out_options Keita Morisaki
@ 2026-03-07 15:29 ` Eric Dumazet
2026-03-10 2:00 ` patchwork-bot+netdevbpf
1 sibling, 0 replies; 3+ messages in thread
From: Eric Dumazet @ 2026-03-07 15:29 UTC (permalink / raw)
To: Keita Morisaki
Cc: ncardwell, kuniyu, davem, dsahern, kuba, pabeni, horms, netdev,
linux-kernel, jakub
On Sat, Mar 7, 2026 at 6:16 AM Keita Morisaki <kmta1236@gmail.com> wrote:
>
> hash_size is declared but never read. The MD5 path always uses a
> fixed size of 16, and the TCP-AO path uses tcp_ao_maclen().
>
> This closes a 7-byte hole and reduces the struct size from 96 to
> 88 bytes.
>
> Suggested-by: Jakub Sitnicki <jakub@cloudflare.com>
> Signed-off-by: Keita Morisaki <kmta1236@gmail.com>
> Reviewed-by: Kuniyuki Iwashima <kuniyu@google.com>
> ---
Reviewed-by: Eric Dumazet <edumazet@google.com>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH net-next v2] tcp: remove unused hash_size from struct tcp_out_options
2026-03-07 5:16 [PATCH net-next v2] tcp: remove unused hash_size from struct tcp_out_options Keita Morisaki
2026-03-07 15:29 ` Eric Dumazet
@ 2026-03-10 2:00 ` patchwork-bot+netdevbpf
1 sibling, 0 replies; 3+ messages in thread
From: patchwork-bot+netdevbpf @ 2026-03-10 2:00 UTC (permalink / raw)
To: Keita Morisaki
Cc: edumazet, ncardwell, kuniyu, davem, dsahern, kuba, pabeni, horms,
netdev, linux-kernel, jakub
Hello:
This patch was applied to netdev/net-next.git (main)
by Jakub Kicinski <kuba@kernel.org>:
On Sat, 7 Mar 2026 14:16:19 +0900 you wrote:
> hash_size is declared but never read. The MD5 path always uses a
> fixed size of 16, and the TCP-AO path uses tcp_ao_maclen().
>
> This closes a 7-byte hole and reduces the struct size from 96 to
> 88 bytes.
>
> Suggested-by: Jakub Sitnicki <jakub@cloudflare.com>
> Signed-off-by: Keita Morisaki <kmta1236@gmail.com>
> Reviewed-by: Kuniyuki Iwashima <kuniyu@google.com>
>
> [...]
Here is the summary with links:
- [net-next,v2] tcp: remove unused hash_size from struct tcp_out_options
https://git.kernel.org/netdev/net-next/c/8ca8eb057673
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] 3+ messages in thread
end of thread, other threads:[~2026-03-10 2:00 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-03-07 5:16 [PATCH net-next v2] tcp: remove unused hash_size from struct tcp_out_options Keita Morisaki
2026-03-07 15:29 ` Eric Dumazet
2026-03-10 2:00 ` 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