linux-nfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/2] SUNRPC: Don't allow waiting for exiting tasks
@ 2025-03-28 17:40 trondmy
  2025-03-28 17:40 ` [PATCH 2/2] NFS: " trondmy
                   ` (2 more replies)
  0 siblings, 3 replies; 17+ messages in thread
From: trondmy @ 2025-03-28 17:40 UTC (permalink / raw)
  To: linux-nfs

From: Trond Myklebust <trond.myklebust@hammerspace.com>

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

Signed-off-by: Trond Myklebust <trond.myklebust@hammerspace.com>
---
 net/sunrpc/sched.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/net/sunrpc/sched.c b/net/sunrpc/sched.c
index 9b45fbdc90ca..73bc39281ef5 100644
--- a/net/sunrpc/sched.c
+++ b/net/sunrpc/sched.c
@@ -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;
-- 
2.49.0


^ permalink raw reply related	[flat|nested] 17+ messages in thread

end of thread, other threads:[~2025-08-19 10:07 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-03-28 17:40 [PATCH 1/2] SUNRPC: Don't allow waiting for exiting tasks trondmy
2025-03-28 17:40 ` [PATCH 2/2] NFS: " trondmy
2025-03-28 18:23   ` Jeff Layton
2025-03-28 17:53 ` [PATCH 1/2] SUNRPC: " Jeff Layton
2025-03-28 18:00   ` Trond Myklebust
2025-03-28 18:09     ` Jeff Layton
2025-03-28 19:36       ` Trond Myklebust
2025-04-08 10:31 ` Mark Brown
2025-07-23  7:02   ` Harshvardhan Jha
2025-07-23  8:07     ` NeilBrown
2025-07-25 11:59       ` Harshvardhan Jha
2025-07-27  4:50         ` NeilBrown
2025-07-28  8:07           ` Harshvardhan Jha
2025-07-28  9:34             ` NeilBrown
2025-08-04  7:45               ` Harshvardhan Jha
2025-08-06  5:47                 ` Harshvardhan Jha
2025-08-19 10:06                   ` Harshvardhan Jha

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).