Skip to content

Commit 14e8e0f

Browse files
nealcardwellkuba-moo
authored andcommitted
tcp: shrink inet_connection_sock icsk_mtup enabled and probe_size
This commit shrinks inet_connection_sock by 4 bytes, by shrinking icsk_mtup.enabled from 32 bits to 1 bit, and shrinking icsk_mtup.probe_size from s32 to an unsuigned 31 bit field. This is to save space to compensate for the recent introduction of a new u32 in inet_connection_sock, icsk_probes_tstamp, in the recent bug fix commit 9d9b1ee ("tcp: fix TCP_USER_TIMEOUT with zero window"). This should not change functionality, since icsk_mtup.enabled is only ever set to 0 or 1, and icsk_mtup.probe_size can only be either 0 or a positive MTU value returned by tcp_mss_to_mtu() Signed-off-by: Neal Cardwell <[email protected]> Signed-off-by: Eric Dumazet <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Jakub Kicinski <[email protected]>
1 parent 4e146de commit 14e8e0f

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

include/net/inet_connection_sock.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -120,14 +120,14 @@ struct inet_connection_sock {
120120
__u16 rcv_mss; /* MSS used for delayed ACK decisions */
121121
} icsk_ack;
122122
struct {
123-
int enabled;
124-
125123
/* Range of MTUs to search */
126124
int search_high;
127125
int search_low;
128126

129127
/* Information on the current probe. */
130-
int probe_size;
128+
u32 probe_size:31,
129+
/* Is the MTUP feature enabled for this connection? */
130+
enabled:1;
131131

132132
u32 probe_timestamp;
133133
} icsk_mtup;

0 commit comments

Comments
 (0)