diff options
author | David Howells <dhowells@redhat.com> | 2016-06-27 17:11:19 +0100 |
---|---|---|
committer | David Howells <dhowells@redhat.com> | 2016-07-06 10:43:51 +0100 |
commit | dee46364ce6fd0815ad9da625783eda21ccf7b06 (patch) | |
tree | 1d4b7d3d3aa9198475f272bbc2ce8be81368b9ad /net/rxrpc/conn_event.c | |
parent | e653cfe49cec540529217933e07caf6c0f25ac93 (diff) | |
download | op-kernel-dev-dee46364ce6fd0815ad9da625783eda21ccf7b06.zip op-kernel-dev-dee46364ce6fd0815ad9da625783eda21ccf7b06.tar.gz |
rxrpc: Add RCU destruction for connections and calls
Add RCU destruction for connections and calls as the RCU lookup from the
transport socket data_ready handler is going to come along shortly.
Whilst we're at it, move the cleanup workqueue flushing and RCU barrierage
into the destruction code for the objects that need it (locals and
connections) and add the extra RCU barrier required for connection cleanup.
Signed-off-by: David Howells <dhowells@redhat.com>
Diffstat (limited to 'net/rxrpc/conn_event.c')
-rw-r--r-- | net/rxrpc/conn_event.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/net/rxrpc/conn_event.c b/net/rxrpc/conn_event.c index 9ceddd3..f6ca8c5 100644 --- a/net/rxrpc/conn_event.c +++ b/net/rxrpc/conn_event.c @@ -198,7 +198,10 @@ static int rxrpc_process_event(struct rxrpc_connection *conn, if (conn->state == RXRPC_CONN_SERVICE_CHALLENGING) { conn->state = RXRPC_CONN_SERVICE; for (loop = 0; loop < RXRPC_MAXCALLS; loop++) - rxrpc_call_is_secure(conn->channels[loop]); + rxrpc_call_is_secure( + rcu_dereference_protected( + conn->channels[loop], + lockdep_is_held(&conn->lock))); } spin_unlock(&conn->state_lock); |