mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-12-02 00:24:12 +08:00
SUNRPC: Fix an RCU dereference in xs_local_rpcbind
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
This commit is contained in:
parent
1b092092bf
commit
3dc0da278e
@ -1731,7 +1731,9 @@ static int xs_bind(struct sock_xprt *transport, struct socket *sock)
|
||||
*/
|
||||
static void xs_local_rpcbind(struct rpc_task *task)
|
||||
{
|
||||
xprt_set_bound(task->tk_xprt);
|
||||
rcu_read_lock();
|
||||
xprt_set_bound(rcu_dereference(task->tk_client->cl_xprt));
|
||||
rcu_read_unlock();
|
||||
}
|
||||
|
||||
static void xs_local_set_port(struct rpc_xprt *xprt, unsigned short port)
|
||||
|
Loading…
Reference in New Issue
Block a user