diff options
author | Eric Dumazet <edumazet@google.com> | 2015-10-02 18:43:23 (GMT) |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2015-10-03 11:32:36 (GMT) |
commit | fff1f3001cc58b5064a0f1154a7ac09b76f29c44 (patch) | |
tree | 910fe6f27dc9b9b7c6a0a56a9442ee264c9a6667 /net/core | |
parent | f6d3125fa3c2f55ddf7cf69365c41089de6cfae6 (diff) | |
download | linux-fff1f3001cc58b5064a0f1154a7ac09b76f29c44.tar.xz |
tcp: add a spinlock to protect struct request_sock_queue
struct request_sock_queue fields are currently protected
by the listener 'lock' (not a real spinlock)
We need to add a private spinlock instead, so that softirq handlers
creating children do not have to worry with backlog notion
that the listener 'lock' carries.
Signed-off-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/core')
-rw-r--r-- | net/core/request_sock.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/net/core/request_sock.c b/net/core/request_sock.c index e22cfa4..8d9fd31 100644 --- a/net/core/request_sock.c +++ b/net/core/request_sock.c @@ -58,6 +58,7 @@ int reqsk_queue_alloc(struct request_sock_queue *queue, return -ENOMEM; get_random_bytes(&lopt->hash_rnd, sizeof(lopt->hash_rnd)); + spin_lock_init(&queue->rskq_lock); spin_lock_init(&queue->syn_wait_lock); spin_lock_init(&queue->fastopenq.lock); |