]> git.hungrycats.org Git - linux/commitdiff
SUNRPC: xs_reset_transport must mark the connection as disconnected
authorTrond Myklebust <trond.myklebust@primarydata.com>
Sat, 29 Aug 2015 20:36:30 +0000 (13:36 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 29 Sep 2015 17:33:31 +0000 (19:33 +0200)
commit 0c78789e3a030615c6650fde89546cadf40ec2cc upstream.

In case the reconnection attempt fails.

Signed-off-by: Trond Myklebust <trond.myklebust@primarydata.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
net/sunrpc/xprtsock.c

index 86ed778bb18b2bc27d204f88e3afbb15440964c2..11f4013caa14a4cfccf7f0db124953e861e10f6d 100644 (file)
@@ -829,6 +829,7 @@ static void xs_reset_transport(struct sock_xprt *transport)
        sk->sk_user_data = NULL;
 
        xs_restore_old_callbacks(transport, sk);
+       xprt_clear_connected(xprt);
        write_unlock_bh(&sk->sk_callback_lock);
        xs_sock_reset_connection_flags(xprt);