From: Jaegeuk Kim <jaegeuk@kernel.org>
To: linux-kernel@vger.kernel.org, linux-fsdevel@vger.kernel.org,
linux-f2fs-devel@lists.sourceforge.net
Cc: Jaegeuk Kim <jaegeuk@kernel.org>
Subject: [PATCH 3/3] f2fs: support clone_file_range
Date: Sat, 16 Jul 2016 23:24:27 -0700 [thread overview]
Message-ID: <20160717062427.56718-3-jaegeuk@kernel.org> (raw)
In-Reply-To: <20160717062427.56718-1-jaegeuk@kernel.org>
This patch implements clone_file_range in f2fs.
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
---
fs/f2fs/file.c | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/fs/f2fs/file.c b/fs/f2fs/file.c
index c2b7e35..37480f3 100644
--- a/fs/f2fs/file.c
+++ b/fs/f2fs/file.c
@@ -2312,6 +2312,12 @@ ssize_t f2fs_copy_file_range(struct file *file_in, loff_t pos_in,
return ret;
}
+int f2fs_clone_file_range(struct file *file_in, loff_t pos_in,
+ struct file *file_out, loff_t pos_out, u64 len)
+{
+ return f2fs_clone_files(file_in, pos_in, file_out, pos_out, len);
+}
+
#ifdef CONFIG_COMPAT
long f2fs_compat_ioctl(struct file *file, unsigned int cmd, unsigned long arg)
{
@@ -2359,6 +2365,7 @@ const struct file_operations f2fs_file_operations = {
.compat_ioctl = f2fs_compat_ioctl,
#endif
.copy_file_range = f2fs_copy_file_range,
+ .clone_file_range = f2fs_clone_file_range,
.splice_read = generic_file_splice_read,
.splice_write = iter_file_splice_write,
};
--
2.8.3
next prev parent reply other threads:[~2016-07-17 6:24 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-07-17 6:24 [PATCH 1/3] f2fs: avoid memory allocation failure due to a long length Jaegeuk Kim
2016-07-17 6:24 ` [PATCH 2/3] f2fs: support copy_file_range Jaegeuk Kim
2016-07-18 17:19 ` Jaegeuk Kim
2016-07-17 6:24 ` Jaegeuk Kim [this message]
2016-07-19 3:47 ` [PATCH 3/3] f2fs: support clone_file_range Christoph Hellwig
2016-07-19 4:48 ` Jaegeuk Kim
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=20160717062427.56718-3-jaegeuk@kernel.org \
--to=jaegeuk@kernel.org \
--cc=linux-f2fs-devel@lists.sourceforge.net \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).