Commit 14e41b16 authored by Trond Myklebust's avatar Trond Myklebust
Browse files

SUNRPC: Don't allow waiting for exiting tasks



Once a task calls exit_signals() it can no longer be signalled. So do
not allow it to do killable waits.

Reviewed-by: default avatarJeff Layton <jlayton@kernel.org>
Signed-off-by: default avatarTrond Myklebust <trond.myklebust@hammerspace.com>
parent 0af5fb5e
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -276,6 +276,8 @@ EXPORT_SYMBOL_GPL(rpc_destroy_wait_queue);

static int rpc_wait_bit_killable(struct wait_bit_key *key, int mode)
{
	if (unlikely(current->flags & PF_EXITING))
		return -EINTR;
	schedule();
	if (signal_pending_state(mode, current))
		return -ERESTARTSYS;