diff options
author | Jens Axboe <jens.axboe@oracle.com> | 2009-07-28 10:16:52 +0200 |
---|---|---|
committer | Jens Axboe <jens.axboe@oracle.com> | 2009-07-28 10:16:52 +0200 |
commit | ebaad3d43f1629be3d5efa823ffae9ba6d807c68 (patch) | |
tree | e1a087f71578b0a566a75a7b7006d96be453df9c /block | |
parent | c57288fb575d8ec695ce898c8e70e2a504a0274b (diff) |
elevator: don't negate flag checking in elv_rq_merge_ok()
The flag testing returns bools now, so no need to negate the checks.
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
Diffstat (limited to 'block')
-rw-r--r-- | block/elevator.c | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/block/elevator.c b/block/elevator.c index 2d511f9105e1..40b112c967af 100644 --- a/block/elevator.c +++ b/block/elevator.c @@ -102,15 +102,10 @@ int elv_rq_merge_ok(struct request *rq, struct bio *bio) /* * Don't merge if failfast settings don't match. - * - * FIXME: The negation in front of each condition is necessary - * because bio and request flags use different bit positions - * and the accessors return those bits directly. This - * ugliness will soon go away. */ - if (!bio_failfast_dev(bio) != !blk_failfast_dev(rq) || - !bio_failfast_transport(bio) != !blk_failfast_transport(rq) || - !bio_failfast_driver(bio) != !blk_failfast_driver(rq)) + if (bio_failfast_dev(bio) != blk_failfast_dev(rq) || + bio_failfast_transport(bio) != blk_failfast_transport(rq) || + bio_failfast_driver(bio) != blk_failfast_driver(rq)) return 0; if (!elv_iosched_allow_merge(rq, bio)) |