diff options
author | Corrado Zoccolo <czoccolo@gmail.com> | 2009-11-02 10:40:37 +0100 |
---|---|---|
committer | Jens Axboe <jens.axboe@oracle.com> | 2009-11-02 10:40:37 +0100 |
commit | dddb74519aec2081204d203a97578c9fc4e9fb64 (patch) | |
tree | 8737fb08028c1d0bbf01775704a7dc41501bbf71 /block | |
parent | ab0a9735e06914ce4d2a94ffa41497dbc142fe7f (diff) | |
download | lwn-dddb74519aec2081204d203a97578c9fc4e9fb64.tar.gz lwn-dddb74519aec2081204d203a97578c9fc4e9fb64.zip |
cfq-iosched: simplify prio-unboost code
Eliminate redundant checks.
Signed-off-by: Corrado Zoccolo <czoccolo@gmail.com>
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
Diffstat (limited to 'block')
-rw-r--r-- | block/cfq-iosched.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/block/cfq-iosched.c b/block/cfq-iosched.c index 418da9a49bb0..757010d8fb7a 100644 --- a/block/cfq-iosched.c +++ b/block/cfq-iosched.c @@ -2359,12 +2359,10 @@ static void cfq_prio_boost(struct cfq_queue *cfqq) cfqq->ioprio = IOPRIO_NORM; } else { /* - * check if we need to unboost the queue + * unboost the queue (if needed) */ - if (cfqq->ioprio_class != cfqq->org_ioprio_class) - cfqq->ioprio_class = cfqq->org_ioprio_class; - if (cfqq->ioprio != cfqq->org_ioprio) - cfqq->ioprio = cfqq->org_ioprio; + cfqq->ioprio_class = cfqq->org_ioprio_class; + cfqq->ioprio = cfqq->org_ioprio; } } |