summaryrefslogtreecommitdiff
path: root/drivers/pwm/pwm-tegra.c
diff options
context:
space:
mode:
authorDamien Le Moal <damien.lemoal@wdc.com>2020-11-20 10:55:13 +0900
committerJens Axboe <axboe@kernel.dk>2020-12-07 17:36:03 -0700
commit817046ecddbc5f3cdd93fb84dd58c58ced987dee (patch)
tree6b4b1bf2f8b78e8023a62d687d56f38ef694297b /drivers/pwm/pwm-tegra.c
parent2e896d89510f23927ec393bee1e0570db3d5a6c6 (diff)
block: Align max_hw_sectors to logical blocksize
Block device drivers do not have to call blk_queue_max_hw_sectors() to set a limit on request size if the default limit BLK_SAFE_MAX_SECTORS is acceptable. However, this limit (255 sectors) may not be aligned to the device logical block size which cannot be used as is for a request maximum size. This is the case for the null_blk device driver. Modify blk_queue_max_hw_sectors() to make sure that the request size limits specified by the max_hw_sectors and max_sectors queue limits are always aligned to the device logical block size. Additionally, to avoid introducing a dependence on the execution order of this function with blk_queue_logical_block_size(), also modify blk_queue_logical_block_size() to perform the same alignment when the logical block size is set after max_hw_sectors. Signed-off-by: Damien Le Moal <damien.lemoal@wdc.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Johannes Thumshirn <johannes.thumshirn@wdc.com> Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'drivers/pwm/pwm-tegra.c')
0 files changed, 0 insertions, 0 deletions