aboutsummaryrefslogtreecommitdiffstats
path: root/block/cfq-iosched.c
diff options
context:
space:
mode:
Diffstat (limited to 'block/cfq-iosched.c')
-rw-r--r--block/cfq-iosched.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/block/cfq-iosched.c b/block/cfq-iosched.c
index 96f59ae5b6e9..f3f62394b986 100644
--- a/block/cfq-iosched.c
+++ b/block/cfq-iosched.c
@@ -2151,10 +2151,11 @@ static struct cfq_queue *cfq_select_queue(struct cfq_data *cfqd)
2151 * have been idling all along on this queue and it should be 2151 * have been idling all along on this queue and it should be
2152 * ok to wait for this request to complete. 2152 * ok to wait for this request to complete.
2153 */ 2153 */
2154 if (cfqq->cfqg->nr_cfqq == 1 && cfqq->dispatched 2154 if (cfqq->cfqg->nr_cfqq == 1 && RB_EMPTY_ROOT(&cfqq->sort_list)
2155 && cfq_should_idle(cfqd, cfqq)) 2155 && cfqq->dispatched && cfq_should_idle(cfqd, cfqq)) {
2156 cfqq = NULL;
2156 goto keep_queue; 2157 goto keep_queue;
2157 else 2158 } else
2158 goto expire; 2159 goto expire;
2159 } 2160 }
2160 2161