diff options
author | Jens Axboe <jaxboe@fusionio.com> | 2011-07-23 14:34:59 -0400 |
---|---|---|
committer | Jens Axboe <jaxboe@fusionio.com> | 2011-07-23 14:34:59 -0400 |
commit | 4c64500eada358165d0bb9a20d6c7d30821995b4 (patch) | |
tree | 27cb0aed7b45d5043d6bbb0b3471719e9230c868 /block | |
parent | d7b7630130e52361af66ce3b994696e2357ba7de (diff) |
block: fix patch import error in max_discard_sectors check
A '!' snuck in before the unlikely, rendering it useless.
Reported-by: Mike Snitzer <snitzer@redhat.com>
Signed-off-by: Jens Axboe <jaxboe@fusionio.com>
Diffstat (limited to 'block')
-rw-r--r-- | block/blk-lib.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/block/blk-lib.c b/block/blk-lib.c index 64974b1c7cca..2b461b496a78 100644 --- a/block/blk-lib.c +++ b/block/blk-lib.c | |||
@@ -59,7 +59,7 @@ int blkdev_issue_discard(struct block_device *bdev, sector_t sector, | |||
59 | * granularity | 59 | * granularity |
60 | */ | 60 | */ |
61 | max_discard_sectors = min(q->limits.max_discard_sectors, UINT_MAX >> 9); | 61 | max_discard_sectors = min(q->limits.max_discard_sectors, UINT_MAX >> 9); |
62 | if (!unlikely(!max_discard_sectors)) { | 62 | if (unlikely(!max_discard_sectors)) { |
63 | /* Avoid infinite loop below. Being cautious never hurts. */ | 63 | /* Avoid infinite loop below. Being cautious never hurts. */ |
64 | return -EOPNOTSUPP; | 64 | return -EOPNOTSUPP; |
65 | } else if (q->limits.discard_granularity) { | 65 | } else if (q->limits.discard_granularity) { |