iomap: allow the file system to provide a bio_set for direct I/O
authorChristoph Hellwig <hch@lst.de>
Thu, 5 May 2022 20:11:10 +0000 (15:11 -0500)
committerDavid Sterba <dsterba@suse.com>
Mon, 16 May 2022 15:17:32 +0000 (17:17 +0200)
commit908c54909ae72dcbf1d7e1440f7297187d06c275
treee51f5510b447ee1ce4908c19ad26c45e3cf8dc18
parent36e8c62273aaa1cb72919212356f2e75e04bcf3c
iomap: allow the file system to provide a bio_set for direct I/O

Allow the file system to provide a specific bio_set for allocating
direct I/O bios.  This will allow file systems that use the
->submit_io hook to stash away additional information for file system
use.

To make use of this additional space for information in the completion
path, the file system needs to override the ->bi_end_io callback and
then call back into iomap, so export iomap_dio_bio_end_io for that.

Reviewed-by: Darrick J. Wong <djwong@kernel.org>
Reviewed-by: Nikolay Borisov <nborisov@suse.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/iomap/direct-io.c
include/linux/iomap.h