From: Olga Kornievskaia Date: Wed, 29 May 2019 14:46:00 +0000 (-0400) Subject: SUNRPC fix regression in umount of a secure mount X-Git-Tag: v5.1.9~45 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ca41657949ab1a1f04b6fc2d9d30d32b13b5677d;p=thirdparty%2Fkernel%2Fstable.git SUNRPC fix regression in umount of a secure mount commit ec6017d9035986a36de064f48a63245930bfad6f upstream. If call_status returns ENOTCONN, we need to re-establish the connection state after. Otherwise the client goes into an infinite loop of call_encode, call_transmit, call_status (ENOTCONN), call_encode. Fixes: c8485e4d63 ("SUNRPC: Handle ECONNREFUSED correctly in xprt_transmit()") Signed-off-by: Olga Kornievskaia Cc: stable@vger.kernel.org # v2.6.29+ Signed-off-by: Anna Schumaker Signed-off-by: Greg Kroah-Hartman --- diff --git a/net/sunrpc/clnt.c b/net/sunrpc/clnt.c index 8ff11dc98d7f9..13dfd3b33b377 100644 --- a/net/sunrpc/clnt.c +++ b/net/sunrpc/clnt.c @@ -2260,13 +2260,13 @@ call_status(struct rpc_task *task) case -ECONNREFUSED: case -ECONNRESET: case -ECONNABORTED: + case -ENOTCONN: rpc_force_rebind(clnt); /* fall through */ case -EADDRINUSE: rpc_delay(task, 3*HZ); /* fall through */ case -EPIPE: - case -ENOTCONN: case -EAGAIN: break; case -EIO: