diff options
Diffstat (limited to 'net/ipv4/tcp_input.c')
-rw-r--r-- | net/ipv4/tcp_input.c | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/net/ipv4/tcp_input.c b/net/ipv4/tcp_input.c index 17b78582ba63..5a17cfc75326 100644 --- a/net/ipv4/tcp_input.c +++ b/net/ipv4/tcp_input.c | |||
@@ -78,7 +78,6 @@ | |||
78 | #include <linux/errqueue.h> | 78 | #include <linux/errqueue.h> |
79 | #include <trace/events/tcp.h> | 79 | #include <trace/events/tcp.h> |
80 | #include <linux/static_key.h> | 80 | #include <linux/static_key.h> |
81 | #include <linux/sock_diag.h> | ||
82 | 81 | ||
83 | int sysctl_tcp_max_orphans __read_mostly = NR_FILE; | 82 | int sysctl_tcp_max_orphans __read_mostly = NR_FILE; |
84 | 83 | ||
@@ -6191,15 +6190,10 @@ struct request_sock *inet_reqsk_alloc(const struct request_sock_ops *ops, | |||
6191 | #if IS_ENABLED(CONFIG_IPV6) | 6190 | #if IS_ENABLED(CONFIG_IPV6) |
6192 | ireq->pktopts = NULL; | 6191 | ireq->pktopts = NULL; |
6193 | #endif | 6192 | #endif |
6193 | atomic64_set(&ireq->ir_cookie, 0); | ||
6194 | ireq->ireq_state = TCP_NEW_SYN_RECV; | 6194 | ireq->ireq_state = TCP_NEW_SYN_RECV; |
6195 | write_pnet(&ireq->ireq_net, sock_net(sk_listener)); | 6195 | write_pnet(&ireq->ireq_net, sock_net(sk_listener)); |
6196 | ireq->ireq_family = sk_listener->sk_family; | 6196 | ireq->ireq_family = sk_listener->sk_family; |
6197 | |||
6198 | BUILD_BUG_ON(offsetof(struct inet_request_sock, ir_cookie) != | ||
6199 | offsetof(struct sock, sk_cookie)); | ||
6200 | BUILD_BUG_ON(offsetof(struct inet_request_sock, ireq_net) != | ||
6201 | offsetof(struct sock, sk_net)); | ||
6202 | sock_init_cookie((struct sock *)ireq); | ||
6203 | } | 6197 | } |
6204 | 6198 | ||
6205 | return req; | 6199 | return req; |