block: blk_max_size_offset() should check ->max_sectors
Commit 762380ad93
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>
This commit is contained in:
parent
d891fa7087
commit
736ed4de76
1 changed files with 1 additions and 1 deletions
|
@ -920,7 +920,7 @@ static inline unsigned int blk_max_size_offset(struct request_queue *q,
|
|||
sector_t offset)
|
||||
{
|
||||
if (!q->limits.chunk_sectors)
|
||||
return q->limits.max_hw_sectors;
|
||||
return q->limits.max_sectors;
|
||||
|
||||
return q->limits.chunk_sectors -
|
||||
(offset & (q->limits.chunk_sectors - 1));
|
||||
|
|
Loading…
Reference in a new issue