Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 4ecef6f2 authored by Trond Myklebust's avatar Trond Myklebust Committed by Greg Kroah-Hartman
Browse files

SUNRPC: Handle low memory situations in call_status()



[ Upstream commit 9d82819d5b065348ce623f196bf601028e22ed00 ]

We need to handle ENFILE, ENOBUFS, and ENOMEM, because
xprt_wake_pending_tasks() can be called with any one of these due to
socket creation failures.

Fixes: b61d59ff ("SUNRPC: xs_tcp_connect_worker{4,6}: merge common code")
Signed-off-by: default avatarTrond Myklebust <trond.myklebust@hammerspace.com>
Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
parent 9a0da98a
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -2394,6 +2394,11 @@ call_status(struct rpc_task *task)
	case -EPIPE:
	case -EAGAIN:
		break;
	case -ENFILE:
	case -ENOBUFS:
	case -ENOMEM:
		rpc_delay(task, HZ>>2);
		break;
	case -EIO:
		/* shutdown or soft timeout */
		goto out_exit;