summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2023-07-24 09:54:30 -0700
committerJens Axboe <axboe@kernel.dk>2023-07-24 19:55:16 -0600
commit613699050a49760f1d70c74f71bd0b013ca3c356 (patch)
tree1117f66979ad0ad87e929850920077c7debf8eaa /scripts
parent0eca8b6f97ac705c5806f7d062207379094fb114 (diff)
block: move the bi_size overflow check in __bio_try_merge_page
Checking for availability in bi_size in a function that attempts to merge into an existing segment is a bit odd, as the limit also applies when adding a new segment. This code works fine as we always call __bio_try_merge_page, but contributes to sub-optimal calling conventions and doesn't lead to clear code. Move it to two of the callers instead, the third one already has a more strict check that includes max_hw_segments anyway. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Jinyoung Choi <j-young.choi@samsung.com> Reviewed-by: Johannes Thumshirn <johannes.thumshirn@wdc.com> Link: https://lore.kernel.org/r/20230724165433.117645-6-hch@lst.de Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'scripts')
0 files changed, 0 insertions, 0 deletions