diff options
author | Trond Myklebust <Trond.Myklebust@netapp.com> | 2012-11-01 16:44:05 -0400 |
---|---|---|
committer | Trond Myklebust <Trond.Myklebust@netapp.com> | 2012-12-05 18:30:51 -0500 |
commit | 1e1093c7fd4951bb4272212c238d09cd7a22f5fc (patch) | |
tree | 6a4abee1ee3a3e45fad908761cecd1e4a8a650e4 | |
parent | 104287cd4ebb5484c654551c102c25c94227f717 (diff) |
NFSv4.1: Don't mess with task priorities in nfs41_setup_sequence
We want to preserve the rpc_task priority for things like writebacks,
that may have differing levels of urgency.
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
-rw-r--r-- | fs/nfs/nfs4proc.c | 8 | ||||
-rw-r--r-- | net/sunrpc/sched.c | 1 |
2 files changed, 5 insertions, 4 deletions
diff --git a/fs/nfs/nfs4proc.c b/fs/nfs/nfs4proc.c index 7f8b42781338..99d99a5a3f61 100644 --- a/fs/nfs/nfs4proc.c +++ b/fs/nfs/nfs4proc.c | |||
@@ -536,8 +536,6 @@ int nfs41_setup_sequence(struct nfs4_session *session, | |||
536 | } | 536 | } |
537 | spin_unlock(&tbl->slot_tbl_lock); | 537 | spin_unlock(&tbl->slot_tbl_lock); |
538 | 538 | ||
539 | rpc_task_set_priority(task, RPC_PRIORITY_NORMAL); | ||
540 | |||
541 | args->sa_slot = slot; | 539 | args->sa_slot = slot; |
542 | 540 | ||
543 | dprintk("<-- %s slotid=%d seqid=%d\n", __func__, | 541 | dprintk("<-- %s slotid=%d seqid=%d\n", __func__, |
@@ -556,8 +554,10 @@ out_success: | |||
556 | out_sleep: | 554 | out_sleep: |
557 | /* Privileged tasks are queued with top priority */ | 555 | /* Privileged tasks are queued with top priority */ |
558 | if (args->sa_privileged) | 556 | if (args->sa_privileged) |
559 | rpc_task_set_priority(task, RPC_PRIORITY_PRIVILEGED); | 557 | rpc_sleep_on_priority(&tbl->slot_tbl_waitq, task, |
560 | rpc_sleep_on(&tbl->slot_tbl_waitq, task, NULL); | 558 | NULL, RPC_PRIORITY_PRIVILEGED); |
559 | else | ||
560 | rpc_sleep_on(&tbl->slot_tbl_waitq, task, NULL); | ||
561 | spin_unlock(&tbl->slot_tbl_lock); | 561 | spin_unlock(&tbl->slot_tbl_lock); |
562 | return -EAGAIN; | 562 | return -EAGAIN; |
563 | } | 563 | } |
diff --git a/net/sunrpc/sched.c b/net/sunrpc/sched.c index 85290266bea0..1aefc9fef866 100644 --- a/net/sunrpc/sched.c +++ b/net/sunrpc/sched.c | |||
@@ -379,6 +379,7 @@ void rpc_sleep_on_priority(struct rpc_wait_queue *q, struct rpc_task *task, | |||
379 | __rpc_sleep_on_priority(q, task, action, priority - RPC_PRIORITY_LOW); | 379 | __rpc_sleep_on_priority(q, task, action, priority - RPC_PRIORITY_LOW); |
380 | spin_unlock_bh(&q->lock); | 380 | spin_unlock_bh(&q->lock); |
381 | } | 381 | } |
382 | EXPORT_SYMBOL_GPL(rpc_sleep_on_priority); | ||
382 | 383 | ||
383 | /** | 384 | /** |
384 | * __rpc_do_wake_up_task - wake up a single rpc_task | 385 | * __rpc_do_wake_up_task - wake up a single rpc_task |