diff options
author | Jens Axboe <axboe@fb.com> | 2014-06-18 01:09:29 -0400 |
---|---|---|
committer | Jens Axboe <axboe@fb.com> | 2014-06-18 01:12:02 -0400 |
commit | 736ed4de766d4f0e8e6142dd4f9d73ef61835ed9 (patch) | |
tree | b9c3c80c88ef8c0242a44356301d50e16f071125 | |
parent | d891fa70876b37941a5c5bed813e73beb53ebcf7 (diff) |
block: blk_max_size_offset() should check ->max_sectors
Commit 762380ad9322 inadvertently changed a check for max_sectors
to max_hw_sectors. Revert that part, so we still compare against
max_sectors.
Signed-off-by: Jens Axboe <axboe@fb.com>
-rw-r--r-- | include/linux/blkdev.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h index 31e11051f1ba..713f8b62b435 100644 --- a/include/linux/blkdev.h +++ b/include/linux/blkdev.h | |||
@@ -920,7 +920,7 @@ static inline unsigned int blk_max_size_offset(struct request_queue *q, | |||
920 | sector_t offset) | 920 | sector_t offset) |
921 | { | 921 | { |
922 | if (!q->limits.chunk_sectors) | 922 | if (!q->limits.chunk_sectors) |
923 | return q->limits.max_hw_sectors; | 923 | return q->limits.max_sectors; |
924 | 924 | ||
925 | return q->limits.chunk_sectors - | 925 | return q->limits.chunk_sectors - |
926 | (offset & (q->limits.chunk_sectors - 1)); | 926 | (offset & (q->limits.chunk_sectors - 1)); |