[rh7,28/30] ext4: Attach write_iter and read_iter

Submitted by Kirill Tkhai on May 20, 2020, 4:06 p.m.

Details

Message ID 158999077266.2234365.2617409650183242687.stgit@localhost.localdomain
State New
Series "fs, direct_IO: Switch to iov_iter and allow bio_vec for ext4"
Headers show

Commit Message

Kirill Tkhai May 20, 2020, 4:06 p.m.
Now all ext4 direct_IO code is prepared to work with iov_iter,
so we allow to use it for submitting bvec from kernel.

See aio_write_iter() and aio_read_iter() for the details,
where from it comes.

Signed-off-by: Kirill Tkhai <ktkhai@virtuozzo.com>
---
 fs/ext4/file.c |    2 ++
 1 file changed, 2 insertions(+)

Patch hide | download patch | download mbox

diff --git a/fs/ext4/file.c b/fs/ext4/file.c
index 32b17c61b52b..83f8aaaeda9d 100644
--- a/fs/ext4/file.c
+++ b/fs/ext4/file.c
@@ -583,6 +583,8 @@  const struct file_operations_extend  ext4_file_operations = {
 		.splice_read	= generic_file_splice_read,
 		.splice_write	= generic_file_splice_write,
 		.fallocate	= ext4_fallocate,
+		.read_iter	= generic_file_read_iter,
+		.write_iter	= ext4_file_write_iter,
 	},
 	.mmap_supported_flags = MAP_SYNC,
 };