diff options
Diffstat (limited to 'net/sunrpc/sched.c')
-rw-r--r-- | net/sunrpc/sched.c | 15 |
1 files changed, 6 insertions, 9 deletions
diff --git a/net/sunrpc/sched.c b/net/sunrpc/sched.c index c98873f39aec..4b22910b4461 100644 --- a/net/sunrpc/sched.c +++ b/net/sunrpc/sched.c | |||
@@ -245,9 +245,9 @@ void rpc_init_wait_queue(struct rpc_wait_queue *queue, const char *qname) | |||
245 | } | 245 | } |
246 | EXPORT_SYMBOL(rpc_init_wait_queue); | 246 | EXPORT_SYMBOL(rpc_init_wait_queue); |
247 | 247 | ||
248 | static int rpc_wait_bit_interruptible(void *word) | 248 | static int rpc_wait_bit_killable(void *word) |
249 | { | 249 | { |
250 | if (signal_pending(current)) | 250 | if (fatal_signal_pending(current)) |
251 | return -ERESTARTSYS; | 251 | return -ERESTARTSYS; |
252 | schedule(); | 252 | schedule(); |
253 | return 0; | 253 | return 0; |
@@ -299,9 +299,9 @@ static void rpc_mark_complete_task(struct rpc_task *task) | |||
299 | int __rpc_wait_for_completion_task(struct rpc_task *task, int (*action)(void *)) | 299 | int __rpc_wait_for_completion_task(struct rpc_task *task, int (*action)(void *)) |
300 | { | 300 | { |
301 | if (action == NULL) | 301 | if (action == NULL) |
302 | action = rpc_wait_bit_interruptible; | 302 | action = rpc_wait_bit_killable; |
303 | return wait_on_bit(&task->tk_runstate, RPC_TASK_ACTIVE, | 303 | return wait_on_bit(&task->tk_runstate, RPC_TASK_ACTIVE, |
304 | action, TASK_INTERRUPTIBLE); | 304 | action, TASK_KILLABLE); |
305 | } | 305 | } |
306 | EXPORT_SYMBOL(__rpc_wait_for_completion_task); | 306 | EXPORT_SYMBOL(__rpc_wait_for_completion_task); |
307 | 307 | ||
@@ -690,10 +690,9 @@ static void __rpc_execute(struct rpc_task *task) | |||
690 | 690 | ||
691 | /* sync task: sleep here */ | 691 | /* sync task: sleep here */ |
692 | dprintk("RPC: %5u sync task going to sleep\n", task->tk_pid); | 692 | dprintk("RPC: %5u sync task going to sleep\n", task->tk_pid); |
693 | /* Note: Caller should be using rpc_clnt_sigmask() */ | ||
694 | status = out_of_line_wait_on_bit(&task->tk_runstate, | 693 | status = out_of_line_wait_on_bit(&task->tk_runstate, |
695 | RPC_TASK_QUEUED, rpc_wait_bit_interruptible, | 694 | RPC_TASK_QUEUED, rpc_wait_bit_killable, |
696 | TASK_INTERRUPTIBLE); | 695 | TASK_KILLABLE); |
697 | if (status == -ERESTARTSYS) { | 696 | if (status == -ERESTARTSYS) { |
698 | /* | 697 | /* |
699 | * When a sync task receives a signal, it exits with | 698 | * When a sync task receives a signal, it exits with |
@@ -837,8 +836,6 @@ void rpc_init_task(struct rpc_task *task, struct rpc_clnt *clnt, int flags, cons | |||
837 | kref_get(&clnt->cl_kref); | 836 | kref_get(&clnt->cl_kref); |
838 | if (clnt->cl_softrtry) | 837 | if (clnt->cl_softrtry) |
839 | task->tk_flags |= RPC_TASK_SOFT; | 838 | task->tk_flags |= RPC_TASK_SOFT; |
840 | if (!clnt->cl_intr) | ||
841 | task->tk_flags |= RPC_TASK_NOINTR; | ||
842 | } | 839 | } |
843 | 840 | ||
844 | BUG_ON(task->tk_ops == NULL); | 841 | BUG_ON(task->tk_ops == NULL); |