Commit 30b515f4 authored by David Howells's avatar David Howells

rxrpc: Access socket accept queue under right lock

The socket's accept queue (socket->acceptq) should be accessed under
socket->call_lock, not under the connection lock.
Signed-off-by: default avatarDavid Howells <dhowells@redhat.com>
parent dee46364
...@@ -1089,7 +1089,7 @@ void rxrpc_process_call(struct work_struct *work) ...@@ -1089,7 +1089,7 @@ void rxrpc_process_call(struct work_struct *work)
if (call->state == RXRPC_CALL_SERVER_SECURING) { if (call->state == RXRPC_CALL_SERVER_SECURING) {
_debug("securing"); _debug("securing");
write_lock(&call->conn->lock); write_lock(&call->socket->call_lock);
if (!test_bit(RXRPC_CALL_RELEASED, &call->flags) && if (!test_bit(RXRPC_CALL_RELEASED, &call->flags) &&
!test_bit(RXRPC_CALL_EV_RELEASE, &call->events)) { !test_bit(RXRPC_CALL_EV_RELEASE, &call->events)) {
_debug("not released"); _debug("not released");
...@@ -1097,7 +1097,7 @@ void rxrpc_process_call(struct work_struct *work) ...@@ -1097,7 +1097,7 @@ void rxrpc_process_call(struct work_struct *work)
list_move_tail(&call->accept_link, list_move_tail(&call->accept_link,
&call->socket->acceptq); &call->socket->acceptq);
} }
write_unlock(&call->conn->lock); write_unlock(&call->socket->call_lock);
read_lock(&call->state_lock); read_lock(&call->state_lock);
if (call->state < RXRPC_CALL_COMPLETE) if (call->state < RXRPC_CALL_COMPLETE)
set_bit(RXRPC_CALL_EV_POST_ACCEPT, &call->events); set_bit(RXRPC_CALL_EV_POST_ACCEPT, &call->events);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment