From: Dominique Martinet <asmadeus@codewreck.org>
To: asmadeus@codewreck.org
Cc: linux-kernel@vger.kernel.org,
v9fs-developer@lists.sourceforge.net,
linux-fsdevel@vger.kernel.org,
"Toke Høiland-Jørgensen" <toke@redhat.com>
Subject: [PATCH] fs: 9p: add generic splice_write file operation
Date: Tue, 1 Dec 2020 16:44:56 +0100 [thread overview]
Message-ID: <1606837496-21717-1-git-send-email-asmadeus@codewreck.org> (raw)
In-Reply-To: <20201201151658.GA13180@nautica>
The default splice operations got removed recently, add it back to 9p
with iter_file_splice_write like many other filesystems do.
Fixes: 36e2c7421f02 ("fs: don't allow splice read/write without explicit ops")
Cc: Toke Høiland-Jørgensen <toke@redhat.com>
Signed-off-by: Dominique Martinet <asmadeus@codewreck.org>
---
fs/9p/vfs_file.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/fs/9p/vfs_file.c b/fs/9p/vfs_file.c
index 145f6f83aa9a..5f9c0c796a37 100644
--- a/fs/9p/vfs_file.c
+++ b/fs/9p/vfs_file.c
@@ -668,6 +668,7 @@ const struct file_operations v9fs_cached_file_operations = {
.lock = v9fs_file_lock,
.mmap = v9fs_file_mmap,
.splice_read = generic_file_splice_read,
+ .splice_write = iter_file_splice_write,
.fsync = v9fs_file_fsync,
};
@@ -681,6 +682,7 @@ const struct file_operations v9fs_cached_file_operations_dotl = {
.flock = v9fs_file_flock_dotl,
.mmap = v9fs_file_mmap,
.splice_read = generic_file_splice_read,
+ .splice_write = iter_file_splice_write,
.fsync = v9fs_file_fsync_dotl,
};
@@ -693,6 +695,7 @@ const struct file_operations v9fs_file_operations = {
.lock = v9fs_file_lock,
.mmap = generic_file_readonly_mmap,
.splice_read = generic_file_splice_read,
+ .splice_write = iter_file_splice_write,
.fsync = v9fs_file_fsync,
};
@@ -706,6 +709,7 @@ const struct file_operations v9fs_file_operations_dotl = {
.flock = v9fs_file_flock_dotl,
.mmap = generic_file_readonly_mmap,
.splice_read = generic_file_splice_read,
+ .splice_write = iter_file_splice_write,
.fsync = v9fs_file_fsync_dotl,
};
@@ -718,6 +722,7 @@ const struct file_operations v9fs_mmap_file_operations = {
.lock = v9fs_file_lock,
.mmap = v9fs_mmap_file_mmap,
.splice_read = generic_file_splice_read,
+ .splice_write = iter_file_splice_write,
.fsync = v9fs_file_fsync,
};
@@ -731,5 +736,6 @@ const struct file_operations v9fs_mmap_file_operations_dotl = {
.flock = v9fs_file_flock_dotl,
.mmap = v9fs_mmap_file_mmap,
.splice_read = generic_file_splice_read,
+ .splice_write = iter_file_splice_write,
.fsync = v9fs_file_fsync_dotl,
};
--
2.28.0
next prev parent reply other threads:[~2020-12-01 15:46 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-12-01 13:54 [PATCH] fs: 9p: add generic splice_read file operations Toke Høiland-Jørgensen
2020-12-01 14:57 ` Dominique Martinet
2020-12-01 15:16 ` [V9fs-developer] " Dominique Martinet
2020-12-01 15:23 ` Toke Høiland-Jørgensen
2020-12-01 15:39 ` Dominique Martinet
2020-12-01 20:37 ` Toke Høiland-Jørgensen
2020-12-01 15:44 ` Dominique Martinet [this message]
2020-12-01 19:25 ` [PATCH] fs: 9p: add generic splice_write file operation Christoph Hellwig
2020-12-01 20:37 ` Toke Høiland-Jørgensen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1606837496-21717-1-git-send-email-asmadeus@codewreck.org \
--to=asmadeus@codewreck.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=toke@redhat.com \
--cc=v9fs-developer@lists.sourceforge.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.