diff options
author | Namhyung Kim <namhyung@gmail.com> | 2011-05-24 10:23:21 +0200 |
---|---|---|
committer | Jens Axboe <jaxboe@fusionio.com> | 2011-05-24 10:23:21 +0200 |
commit | b9f8ce059940064a732da49b5d6e618381dad956 (patch) | |
tree | 850281e8dd7bf5813d2960c2d42177803072bc02 /block | |
parent | 4cbadbd16e2fb727f6926597e0a580829e6222f1 (diff) | |
download | kernel_samsung_crespo-b9f8ce059940064a732da49b5d6e618381dad956.zip kernel_samsung_crespo-b9f8ce059940064a732da49b5d6e618381dad956.tar.gz kernel_samsung_crespo-b9f8ce059940064a732da49b5d6e618381dad956.tar.bz2 |
cfq-iosched: algebraic simplification in cfq_prio_to_maxrq()
Simplify the calculation in cfq_prio_to_maxrq(), plus replace CFQ_PRIO_LISTS to
IOPRIO_BE_NR since they are the same and IOPRIO_BE_NR looks more reasonable in
this context IMHO.
Signed-off-by: Namhyung Kim <namhyung@gmail.com>
Signed-off-by: Jens Axboe <jaxboe@fusionio.com>
Diffstat (limited to 'block')
-rw-r--r-- | block/cfq-iosched.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/block/cfq-iosched.c b/block/cfq-iosched.c index 0316f6e..00763e5 100644 --- a/block/cfq-iosched.c +++ b/block/cfq-iosched.c @@ -2102,7 +2102,7 @@ cfq_prio_to_maxrq(struct cfq_data *cfqd, struct cfq_queue *cfqq) WARN_ON(cfqq->ioprio >= IOPRIO_BE_NR); - return 2 * (base_rq + base_rq * (CFQ_PRIO_LISTS - 1 - cfqq->ioprio)); + return 2 * base_rq * (IOPRIO_BE_NR - cfqq->ioprio); } /* |