Skip to content

Commit 3f8ad50

Browse files
edumazetdavem330
authored andcommitted
tcp: change ICSK_CA_PRIV_SIZE definition
Instead of a magic number (13 currently) and having to change it every other year, use sizeof_field() macro. Signed-off-by: Eric Dumazet <[email protected]> Signed-off-by: David S. Miller <[email protected]>
1 parent 6706721 commit 3f8ad50

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

include/net/inet_connection_sock.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@ struct inet_connection_sock {
135135
u32 icsk_user_timeout;
136136

137137
u64 icsk_ca_priv[104 / sizeof(u64)];
138-
#define ICSK_CA_PRIV_SIZE (13 * sizeof(u64))
138+
#define ICSK_CA_PRIV_SIZE sizeof_field(struct inet_connection_sock, icsk_ca_priv)
139139
};
140140

141141
#define ICSK_TIME_RETRANS 1 /* Retransmit timer */

0 commit comments

Comments
 (0)