]> www.infradead.org Git - users/hch/xfs.git/commit
xfs: implement direct writes to zoned RT devices
authorChristoph Hellwig <hch@lst.de>
Mon, 27 Jan 2025 14:35:00 +0000 (15:35 +0100)
committerChristoph Hellwig <hch@lst.de>
Mon, 3 Feb 2025 04:49:12 +0000 (05:49 +0100)
commitbbadcb9f84db5830e27df75ec6c7e8e468c8bfd9
tree111a574e0e461b0accb13f19886805a3d1cd6f91
parent080fb1a020d238046b3edebca42fb7b5b434c752
xfs: implement direct writes to zoned RT devices

Direct writes to zoned RT devices are extremely simple.  After taking the
block reservation before acquiring the iolock, the iomap direct I/O calls
into ->iomap_begin which will return a "fake" iomap for the entire
requested range.  The actual block allocation is then done from the
submit_io handler using code shared with the buffered I/O path.

The iomap_dio_ops set the bio_set to the (iomap) ioend one and initialize
the embedded ioend, which allows reusing the existing ioend based buffered
I/O completion path.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: "Darrick J. Wong" <djwong@kernel.org>
fs/xfs/xfs_aops.c
fs/xfs/xfs_aops.h
fs/xfs/xfs_file.c
fs/xfs/xfs_iomap.c
fs/xfs/xfs_iomap.h