summaryrefslogtreecommitdiff
path: root/block/bio.c
diff options
context:
space:
mode:
authorLogan Gunthorpe <logang@deltatee.com>2022-10-21 11:41:12 -0600
committerJens Axboe <axboe@kernel.dk>2022-11-09 11:29:21 -0700
commit1567b49d1a4081ba7e1a0ff2dc39bc58c59f2a51 (patch)
tree3e8e5f3d3bc23897673cd568cac69a07f85f6c4f /block/bio.c
parent49580e690755d0e51ed7aa2c33225dd884fa738a (diff)
lib/scatterlist: add check when merging zone device pages
Consecutive zone device pages should not be merged into the same sgl or bvec segment with other types of pages or if they belong to different pgmaps. Otherwise getting the pgmap of a given segment is not possible without scanning the entire segment. This helper returns true either if both pages are not zone device pages or both pages are zone device pages with the same pgmap. Factor out the check for page mergability into a pages_are_mergable() helper and add a check with zone_device_pages_are_mergeable(). Signed-off-by: Logan Gunthorpe <logang@deltatee.com> Reviewed-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Chaitanya Kulkarni <kch@nvidia.com> Link: https://lore.kernel.org/r/20221021174116.7200-6-logang@deltatee.com Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'block/bio.c')
0 files changed, 0 insertions, 0 deletions