aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2006-03-14 15:32:50 -0500
committerAl Viro <viro@zeniv.linux.org.uk>2006-03-18 18:33:54 -0500
commitb0a6916bcc48f46996d54b8451591a2f2b7b2f64 (patch)
tree8b22d7d04a802092928a642628d2ede339a5287a
parentc981ff9f893b9ab229a809f8ad287ae43fc17a64 (diff)
[PATCH] fix cfq hash lookups
If somebody does a hash lookup for cfq_queue while ioprio of an async queue is elevated, they shouldn't end up stuck with lowered ioprio when we go back. Fix is to use ->org_ioprio{,class} in hash lookups. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
-rw-r--r--block/cfq-iosched.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/block/cfq-iosched.c b/block/cfq-iosched.c
index c8dbe38c81c..37a2a772498 100644
--- a/block/cfq-iosched.c
+++ b/block/cfq-iosched.c
@@ -1179,7 +1179,7 @@ __cfq_find_cfq_hash(struct cfq_data *cfqd, unsigned int key, unsigned int prio,
hlist_for_each_safe(entry, next, hash_list) {
struct cfq_queue *__cfqq = list_entry_qhash(entry);
- const unsigned short __p = IOPRIO_PRIO_VALUE(__cfqq->ioprio_class, __cfqq->ioprio);
+ const unsigned short __p = IOPRIO_PRIO_VALUE(__cfqq->org_ioprio_class, __cfqq->org_ioprio);
if (__cfqq->key == key && (__p == prio || prio == CFQ_KEY_ANY))
return __cfqq;