On 04/14/2015 12:53 PM, Christoph Hellwig wrote:
On Sat, Apr 11, 2015 at 09:04:02AM -0400, Jeff Layton wrote:
Yuck! How the heck do you clean up the mess if that happens? I guess
you're just stuck redoing the copy with normal READ/WRITE?
Maybe we need to have the interface return a hard error
copy_file_range() is a new system call for copying ranges of data
completely in the kernel. This gives filesystems an opportunity to
implement some kind of "copy acceleration", such as reflinks or
server-side-copy (in the case of NFS).
Signed-off-by: Anna Schumaker <anna.schuma.
the
pagecache.
I moved the rw_verify_area() calls into the fallback code since some
filesystems can handle reflinking a large range.
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
Reviewed-by: Darrick J. Wong <darrick.w...@oracle.com>
Reviewed-by: Padraig Brady <p...@draigbr
devices.
- Meniton sparse file expansion in the man page.
Anna Schumaker (1):
vfs: Add vfs_copy_file_range() support for pagecache copies
Zach Brown (3):
vfs: add copy_file_range syscall and vfs helper
x86: add sys_copy_file_range to syscall tables
btrfs: add .copy_file_range file operation
error checks that should be shared.
Signed-off-by: Zach Brown <z...@redhat.com>
[Anna Schumaker: Make flags an unsigned int]
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
Reviewed-by: Josef Bacik <jba...@fb.com>
Reviewed-by: David Sterba <dste...@suse.com>
---
v7:
safely.
Signed-off-by: Zach Brown <z...@redhat.com>
[Anna Schumaker: Change -EINVAL to -EBADF during file verification,
Change flags parameter from int to unsigned int,
Add function to include/linux/syscalls.h,
Check copy len after fi
From: Zach Brown <z...@redhat.com>
Add sys_copy_file_range to the x86 syscall tables.
Signed-off-by: Zach Brown <z...@redhat.com>
[Anna Schumaker: Update syscall number in syscall_32.tbl]
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
---
arch/x86/entry/syscalls/
From: Zach Brown <z...@redhat.com>
Add sys_copy_file_range to the x86 syscall tables.
Signed-off-by: Zach Brown <z...@redhat.com>
[Anna Schumaker: Update syscall number in syscall_32.tbl]
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
Reviewed-by: Christoph He
error checks that should be shared.
Signed-off-by: Zach Brown <z...@redhat.com>
[Anna Schumaker: Make flags an unsigned int,
Check for COPY_FR_REFLINK]
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
Reviewed-by: Josef Bacik <jba...@fb.com>
Reviewe
safely.
Signed-off-by: Zach Brown <z...@redhat.com>
[Anna Schumaker: Change -EINVAL to -EBADF during file verification,
Change flags parameter from int to unsigned int,
Add function to include/linux/syscalls.h,
Check copy len after fi
-by: Anna Schumaker <anna.schuma...@netapp.com>
Reviewed-by: Darrick J. Wong <darrick.w...@oracle.com>
Reviewed-by: Padraig Brady <p...@draigbrady.com>
Reviewed-by: Christoph Hellwig <h...@lst.de>
---
v9:
- Don't remove call to rw_verify_area()
---
fs/read_write.c | 13
need to keep
writing their own ioctls.
Changes in v9:
- Update syscall number for sys_mlock2()
- Fix calls to rw_verify_area()
Thanks,
Anna
Anna Schumaker (1):
vfs: Add vfs_copy_file_range() support for pagecache copies
Zach Brown (3):
vfs: add copy_file_range syscall and vfs helper
x86
On 11/10/2015 10:38 PM, Al Viro wrote:
> On Tue, Nov 10, 2015 at 04:53:29PM -0500, Anna Schumaker wrote:
>> Copy system calls came up during Plumbers a while ago, mostly because several
>> filesystems (including NFS and XFS) are currently working on copy
>> acceleration
&g
the rw_verify_area() calls into the fallback code since some
filesystems can handle reflinking a large range.
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
Reviewed-by: Darrick J. Wong <darrick.w...@oracle.com>
Reviewed-by: Padraig Brady <p...@draigbrady.com>
Reviewed-by: Ch
error checks that should be shared.
Signed-off-by: Zach Brown <z...@redhat.com>
[Anna Schumaker: Make flags an unsigned int,
Check for COPY_FR_REFLINK]
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
Reviewed-by: Josef Bacik <jba...@fb.com>
Reviewe
safely.
Signed-off-by: Zach Brown <z...@redhat.com>
[Anna Schumaker: Change -EINVAL to -EBADF during file verification,
Change flags parameter from int to unsigned int,
Add function to include/linux/syscalls.h,
Check copy len after fi
I use this function for pagecache copies.
Changes in v8:
- Remove redundant checks.
- Make the fdget() / fdput() calls more obvious.
- Document disallowing files open with O_APPEND.
Thanks,
Anna
Anna Schumaker (1):
vfs: Add vfs_copy_file_range() support for pagecache copies
Zach Brown (3
From: Zach Brown <z...@redhat.com>
Add sys_copy_file_range to the x86 syscall tables.
Signed-off-by: Zach Brown <z...@redhat.com>
[Anna Schumaker: Update syscall number in syscall_32.tbl]
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
Reviewed-by: Christoph He
copy_file_range() is a new system call for copying ranges of data
completely in the kernel. This gives filesystems an opportunity to
implement some kind of "copy acceleration", such as reflinks or
server-side-copy (in the case of NFS).
Signed-off-by: Anna Schumaker <anna.schuma.
ase system call first, and then add that later if it's still desired.
Changes in v6:
- Squash together most patches.
- Drop all flags except COPY_FR_REFLINK.
- Drop patch removing same mountpoint check.
- Change default behavior (flags = 0) to a data copy.
Anna Schumaker (1):
vfs: Add vfs_copy_
error checks that should be shared.
Signed-off-by: Zach Brown <z...@redhat.com>
[Anna Schumaker: Make flags an unsigned int,
Check for COPY_FR_REFLINK]
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
Reviewed-by: Josef Bacik <jba...@fb.com>
Reviewe
copy_file_range() is a new system call for copying ranges of data
completely in the kernel. This gives filesystems an opportunity to
implement some kind of "copy acceleration", such as reflinks or
server-side-copy (in the case of NFS).
Signed-off-by: Anna Schumaker <anna.schuma.
safely.
Signed-off-by: Zach Brown <z...@redhat.com>
[Anna Schumaker: Change -EINVAL to -EBADF during file verification,
Change flags parameter from int to unsigned int,
Add function to include/linux/syscalls.h,
Check copy len after fi
the rw_verify_area() calls into the fallback code since some
filesystems can handle reflinking a large range.
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
Reviewed-by: Darrick J. Wong <darrick.w...@oracle.com>
Reviewed-by: Padraig Brady <p...@draigbrady.com>
---
v6:
- Don't
From: Zach Brown <z...@redhat.com>
Add sys_copy_file_range to the x86 syscall tables.
Signed-off-by: Zach Brown <z...@redhat.com>
[Anna Schumaker: Update syscall number in syscall_32.tbl]
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
---
arch/x86/entry/syscalls/
I would have folded this and patch 4 earlier if I had written patch 1, but I
didn't feel comfortable modifying Zach's work too much. I can make that change
if it's not really a problem.
Anna
On 10/11/2015 10:22 AM, Christoph Hellwig wrote:
> Needs to be folded.
>
--
To unsubscribe from this
On 10/14/2015 02:25 PM, Christoph Hellwig wrote:
> On Wed, Oct 14, 2015 at 01:37:13PM -0400, Anna Schumaker wrote:
>> I would have folded this and patch 4 earlier if I had written patch 1,
>> but I didn't feel comfortable modifying Zach's work too much. I can
>> mak
On 10/11/2015 10:23 AM, Christoph Hellwig wrote:
> On Wed, Sep 30, 2015 at 01:26:51PM -0400, Anna Schumaker wrote:
>> I still want to do an in-kernel copy even if the files are on different
>> mountpoints, and NFS has a "server to server" copy that expects two
>>
On 10/12/2015 07:17 PM, Darrick J. Wong wrote:
> On Sun, Oct 11, 2015 at 07:22:03AM -0700, Christoph Hellwig wrote:
>> On Wed, Sep 30, 2015 at 01:26:52PM -0400, Anna Schumaker wrote:
>>> This allows us to have an in-kernel copy mechanism that avoids frequent
>>> switc
On 10/09/2015 07:15 AM, Pádraig Brady wrote:
> On 08/10/15 02:40, Neil Brown wrote:
>> Anna Schumaker <anna.schuma...@netapp.com> writes:
>>
>>> @@ -1338,34 +1362,26 @@ ssize_t vfs_copy_file_range(struct file *file_in,
>>> loff_t pos_in,
>>>
On 10/07/2015 09:40 PM, Neil Brown wrote:
> Anna Schumaker <anna.schuma...@netapp.com> writes:
>
>> @@ -1338,34 +1362,26 @@ ssize_t vfs_copy_file_range(struct file *file_in,
>> loff_t pos_in,
>> struct file *file_out, loff_t pos_out,
>
safely.
Signed-off-by: Zach Brown <z...@redhat.com>
[Anna Schumaker: Change -EINVAL to -EBADF during file verification]
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
---
fs/read_write.c | 129 ++
include/linux/fs.h
error checks that should be shared.
Signed-off-by: Zach Brown <z...@redhat.com>
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
---
fs/btrfs/ctree.h | 3 ++
fs/btrfs/file.c | 1 +
fs/btrfs/ioctl.c | 91
3 files chan
We need to verify that both the source and the destination files are
part of the same filesystem, otherwise we can't create a reflink.
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
---
fs/btrfs/ioctl.c | 4
1 file changed, 4 insertions(+)
diff --git a/fs/btrfs/ioctl.
I don't think it makes sense to report that a copy succeeded if the
files aren't open properly.
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
---
fs/read_write.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/fs/read_write.c b/fs/read_write.c
index 9
I still want to do an in-kernel copy even if the files are on different
mountpoints, and NFS has a "server to server" copy that expects two
files on different mountpoints. Let's have individual filesystems
implement this check instead.
Signed-off-by: Anna Schumaker <anna.schuma.
copy_file_range() is a new system call for copying ranges of data
completely in the kernel. This gives filesystems an opportunity to
implement some kind of "copy acceleration", such as reflinks or
server-side-copy (in the case of NFS).
Signed-off-by: Anna Schumaker <anna.schuma.
| 0.76s | 0.99s
cpu | 77% | 62% | 60% |59%
total | 0.422 | 0.777 | 1.267 | 1.655
Questions? Comments? Thoughts?
Anna
Anna Schumaker (5):
btrfs: Add mountpoint checking during btrfs_copy_file_range
vfs: Remove copy_file_range mountpoint
the fallback.
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
---
fs/read_write.c | 16
include/linux/copy.h | 6 ++
include/uapi/linux/Kbuild | 1 +
include/uapi/linux/copy.h | 6 ++
4 files changed, 25 insertions(+), 4 deletions(-)
creat
The way to think about this is that the destination filesystem reads the
data from the source file and processes it accordingly. This is
especially important to avoid an infinate loop when doing a "server to
server" copy on NFS.
Signed-off-by: Anna Schumaker <anna.schuma...@netapp
From: Zach Brown <z...@redhat.com>
Add sys_copy_file_range to the x86 syscall tables.
Signed-off-by: Zach Brown <z...@redhat.com>
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
---
arch/x86/entry/syscalls/syscall_32.tbl | 1 +
arch/x86/entry/syscalls/syscall_64.
On 09/08/2015 04:45 PM, Darrick J. Wong wrote:
> On Tue, Sep 08, 2015 at 11:08:03AM -0400, Anna Schumaker wrote:
>> On 09/05/2015 04:33 AM, Al Viro wrote:
>>> On Fri, Sep 04, 2015 at 04:25:27PM -0600, Andreas Dilger wrote:
>>>
>>>> This is a bit of a
On 09/04/2015 05:38 PM, Darrick J. Wong wrote:
> On Fri, Sep 04, 2015 at 04:17:03PM -0400, Anna Schumaker wrote:
>> copy_file_range() is a new system call for copying ranges of data
>> completely in the kernel. This gives filesystems an opportunity to
>> implement some kind
On 09/04/2015 06:31 PM, Andreas Dilger wrote:
> On Sep 4, 2015, at 3:38 PM, Darrick J. Wong <darrick.w...@oracle.com> wrote:
>>
>> On Fri, Sep 04, 2015 at 04:17:03PM -0400, Anna Schumaker wrote:
>>> copy_file_range() is a new system call for copying ranges of dat
On 09/04/2015 06:25 PM, Andreas Dilger wrote:
> On Sep 4, 2015, at 2:16 PM, Anna Schumaker <anna.schuma...@netapp.com> wrote:
>>
>> Copy system calls came up during Plumbers a couple of weeks ago,
>> because several filesystems (including NFS and XFS) are currently
>
On 09/09/2015 05:16 PM, Darrick J. Wong wrote:
> On Wed, Sep 09, 2015 at 02:52:08PM -0400, Anna Schumaker wrote:
>> On 09/08/2015 06:39 PM, Darrick J. Wong wrote:
>>> On Tue, Sep 08, 2015 at 02:45:39PM -0700, Andy Lutomirski wrote:
>>>> On Tue, Sep 8, 2015 at 2:29
On 09/09/2015 05:18 AM, David Sterba wrote:
> On Fri, Sep 04, 2015 at 04:16:58PM -0400, Anna Schumaker wrote:
>> We need to verify that both the source and the destination files are
>> part of the same filesystem, otherwise we can't create a reflink.
>>
>> Si
copy_file_range() is a new system call for copying ranges of data
completely in the kernel. This gives filesystems an opportunity to
implement some kind of "copy acceleration", such as reflinks or
server-side-copy (in the case of NFS).
Signed-off-by: Anna Schumaker <anna.schuma.
From: Zach Brown <z...@redhat.com>
Add sys_copy_file_range to the x86 syscall tables.
Signed-off-by: Zach Brown <z...@redhat.com>
[Anna Schumaker: Update syscall number in syscall_32.tbl]
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
---
arch/x86/entry/syscalls/
Reject copies that don't have the COPY_FR_REFLINK flag set.
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
---
fs/btrfs/ioctl.c | 4
1 file changed, 4 insertions(+)
diff --git a/fs/btrfs/ioctl.c b/fs/btrfs/ioctl.c
index 4311554..2e14b91 100644
--- a/fs/btrfs/ioctl.c
++
This is perfectly valid for BTRFS and XFS, so let's leave this up to
filesystems to check.
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
---
fs/read_write.c | 4
1 file changed, 4 deletions(-)
diff --git a/fs/read_write.c b/fs/read_write.c
index 38cc251..d32549b 100644
--
The way to think about this is that the destination filesystem reads the
data from the source file and processes it accordingly. This is
especially important to avoid an infinate loop when doing a "server to
server" copy on NFS.
Signed-off-by: Anna Schumaker <anna.schuma...@netapp
range.
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
---
v2:
- Rename COPY_REFLINK -> COPY_FR_REFLINK
- Introduce COPY_FR_COPY flag
- Flags == 0 is really COPY_FR_COPY|COPY_FR_REFLINK
- Drop check for invalid flags
- Move call to do_splice_direct() into a new functi
safely.
Signed-off-by: Zach Brown <z...@redhat.com>
[Anna Schumaker: Change -EINVAL to -EBADF during file verification]
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
---
fs/read_write.c | 129 ++
include/linux/fs.h
error checks that should be shared.
Signed-off-by: Zach Brown <z...@redhat.com>
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
Reviewed-by: Josef Bacik <jba...@fb.com>
Reviewed-by: David Sterba <dste...@suse.com>
---
fs/btrfs/ctree.h | 3 ++
fs/btrfs/file.c
00s | 0.00s | 0.00s | 0.00s
system | 0.65s | 0.46s | 0.70s | 0.93s | 1.18s | 1.41s | 2.37s
cpu |35% |14% |15% |14% |14% |14% |14%
total | 1.870 | 3.084 | 4.613 | 6.206 | 7.884 | 9.372 | 15.904
Questions? Comments? Thoughts?
Anna
A
I still want to do an in-kernel copy even if the files are on different
mountpoints, and NFS has a "server to server" copy that expects two
files on different mountpoints. Let's have individual filesystems
implement this check instead.
Signed-off-by: Anna Schumaker <anna.schuma.
I don't think it makes sense to report that a copy succeeded if the
files aren't open properly.
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
---
fs/read_write.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/fs/read_write.c b/fs/read_write.c
index 8
On 09/14/2015 11:32 PM, Darrick J. Wong wrote:
> On Fri, Sep 11, 2015 at 04:30:21PM -0400, Anna Schumaker wrote:
>> The NFS server will need some kind offallback for filesystems that don't
>> have any kind of copy acceleration, and it should be generally useful to
>> h
On 09/28/2015 02:31 PM, Darrick J. Wong wrote:
> On Fri, Sep 25, 2015 at 04:48:14PM -0400, Anna Schumaker wrote:
>> The NFS server will need some kind offallback for filesystems that don't
>
> "some kind of fallback"
I'll rephrase that :)
>
>> have any kind o
On 09/28/2015 02:40 PM, Darrick J. Wong wrote:
> On Fri, Sep 25, 2015 at 04:48:16PM -0400, Anna Schumaker wrote:
>> copy_file_range() is a new system call for copying ranges of data
>> completely in the kernel. This gives filesystems an opportunity to
>> implement some kind
The way to think about this is that the destination filesystem reads the
data from the source file and processes it accordingly. This is
especially important to avoid an infinate loop when doing a "server to
server" copy on NFS.
Signed-off-by: Anna Schumaker <anna.schuma...@netapp
error checks that should be shared.
Signed-off-by: Zach Brown <z...@redhat.com>
[Anna Schumaker: Make flags an unsigned int]
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
Reviewed-by: Josef Bacik <jba...@fb.com>
Reviewed-by: David Sterba <dste...@suse.com>
need to keep
writing their own ioctls.
This posting fixes a few issues that popped up after I submitted v4 yesterday.
Changes in v5:
- Bump syscall number (again)
- Add sys_copy_file_range() to include/linux/syscalls.h
- Change flags parameter on btrfs to an unsigned int
Anna Schumaker (6
From: Zach Brown <z...@redhat.com>
Add sys_copy_file_range to the x86 syscall tables.
Signed-off-by: Zach Brown <z...@redhat.com>
[Anna Schumaker: Update syscall number in syscall_32.tbl]
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
---
arch/x86/entry/syscalls/
This is perfectly valid for BTRFS and XFS, so let's leave this up to
filesystems to check.
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
Reviewed-by: David Sterba <dste...@suse.com>
Reviewed-by: Darrick J. Wong <darrick.w...@oracle.com>
---
fs/read_write.c | 4
Reject copies that don't have the COPY_FR_REFLINK flag set.
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
Reviewed-by: David Sterba <dste...@suse.com>
---
fs/btrfs/ioctl.c | 4
1 file changed, 4 insertions(+)
diff --git a/fs/btrfs/ioctl.c b/fs/btrfs/ioctl.c
i
I don't think it makes sense to report that a copy succeeded if the
files aren't open properly.
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
Reviewed-by: David Sterba <dste...@suse.com>
---
fs/read_write.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
dif
copy_file_range() is a new system call for copying ranges of data
completely in the kernel. This gives filesystems an opportunity to
implement some kind of "copy acceleration", such as reflinks or
server-side-copy (in the case of NFS).
Signed-off-by: Anna Schumaker <anna.schuma.
safely.
Signed-off-by: Zach Brown <z...@redhat.com>
[Anna Schumaker: Change -EINVAL to -EBADF during file verification]
[Anna Schumaker: Change flags parameter from int to unsigned int]
[Anna Schumaker: Add function to include/linux/syscalls.h]
Signed-off-by: Anna Schumaker <anna.schum
the rw_verify_area() calls into the fallback code since some
filesystems can handle reflinking a large range.
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
Reviewed-by: Darrick J. Wong <darrick.w...@oracle.com>
Reviewed-by: Padraig Brady <p...@draigbrady.com>
--
I still want to do an in-kernel copy even if the files are on different
mountpoints, and NFS has a "server to server" copy that expects two
files on different mountpoints. Let's have individual filesystems
implement this check instead.
Signed-off-by: Anna Schumaker <anna.schuma.
On 09/25/2015 08:14 PM, Andy Lutomirski wrote:
> On Fri, Sep 25, 2015 at 1:48 PM, Anna Schumaker
> <anna.schuma...@netapp.com> wrote:
>> The NFS server will need some kind offallback for filesystems that don't
>> have any kind of copy acceleration, and it should be gen
This is perfectly valid for BTRFS and XFS, so let's leave this up to
filesystems to check.
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
Reviewed-by: David Sterba <dste...@suse.com>
Reviewed-by: Darrick J. Wong <darrick.w...@oracle.com>
---
fs/read_write.c | 4
error checks that should be shared.
Signed-off-by: Zach Brown <z...@redhat.com>
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
Reviewed-by: Josef Bacik <jba...@fb.com>
Reviewed-by: David Sterba <dste...@suse.com>
---
fs/btrfs/ctree.h | 3 ++
fs/btrfs/file.c
safely.
Signed-off-by: Zach Brown <z...@redhat.com>
[Anna Schumaker: Change -EINVAL to -EBADF during file verification]
[Anna Schumaker: Change flags parameter from int to unsigned int]
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
---
fs/read_write.c
?
Anna
Anna Schumaker (6):
vfs: Copy should check len after file open mode
vfs: Copy shouldn't forbid ranges inside the same file
vfs: Copy should use file_out rather than file_in
vfs: Remove copy_file_range mountpoint checks
vfs: Add vfs_copy_file_range() support for pagecache copies
I don't think it makes sense to report that a copy succeeded if the
files aren't open properly.
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
Reviewed-by: David Sterba <dste...@suse.com>
---
fs/read_write.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
dif
copy_file_range() is a new system call for copying ranges of data
completely in the kernel. This gives filesystems an opportunity to
implement some kind of "copy acceleration", such as reflinks or
server-side-copy (in the case of NFS).
Signed-off-by: Anna Schumaker <anna.schuma.
From: Zach Brown <z...@redhat.com>
Add sys_copy_file_range to the x86 syscall tables.
Signed-off-by: Zach Brown <z...@redhat.com>
[Anna Schumaker: Update syscall number in syscall_32.tbl]
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
---
arch/x86/entry/syscalls/
The way to think about this is that the destination filesystem reads the
data from the source file and processes it accordingly. This is
especially important to avoid an infinate loop when doing a "server to
server" copy on NFS.
Signed-off-by: Anna Schumaker <anna.schuma...@netapp
the rw_verify_area() calls into the fallback code since some
filesystems can handle reflinking a large range.
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
Reviewed-by: Darrick J. Wong <darrick.w...@oracle.com>
---
v4:
- Reword commit message
- Rename COPY_FR_DEDUPE ->
I still want to do an in-kernel copy even if the files are on different
mountpoints, and NFS has a "server to server" copy that expects two
files on different mountpoints. Let's have individual filesystems
implement this check instead.
Signed-off-by: Anna Schumaker <anna.schuma.
Reject copies that don't have the COPY_FR_REFLINK flag set.
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
Reviewed-by: David Sterba <dste...@suse.com>
---
fs/btrfs/ioctl.c | 4
1 file changed, 4 insertions(+)
diff --git a/fs/btrfs/ioctl.c b/fs/btrfs/ioctl.c
i
:
>>>> On 08/09/15 20:10, Andy Lutomirski wrote:
>>>>> On Tue, Sep 8, 2015 at 11:23 AM, Anna Schumaker
>>>>> <anna.schuma...@netapp.com> wrote:
>>>>>> On 09/08/2015 11:21 AM, Pádraig Brady wrote:
>>>>>>> I see cop
On 09/09/2015 04:38 PM, Chris Mason wrote:
> On Wed, Sep 09, 2015 at 04:26:58PM -0400, Trond Myklebust wrote:
>> On Wed, Sep 9, 2015 at 4:09 PM, Chris Mason wrote:
>>> On Tue, Sep 08, 2015 at 04:08:43PM -0700, Andy Lutomirski wrote:
On Tue, Sep 8, 2015 at 3:39 PM, Darrick J.
On 09/09/2015 01:17 PM, Darrick J. Wong wrote:
> On Wed, Sep 09, 2015 at 07:38:14AM -0400, Austin S Hemmelgarn wrote:
>> On 2015-09-08 16:39, Darrick J. Wong wrote:
>>> On Tue, Sep 08, 2015 at 11:04:03AM -0400, Anna Schumaker wrote:
>>>> On 09/04/2015 05:38 PM, Darri
On 09/09/2015 02:12 PM, Darrick J. Wong wrote:
> On Wed, Sep 09, 2015 at 01:31:24PM -0400, Anna Schumaker wrote:
>> On 09/09/2015 01:17 PM, Darrick J. Wong wrote:
>>> On Wed, Sep 09, 2015 at 07:38:14AM -0400, Austin S Hemmelgarn wrote:
>>>> On 2015-09-08 16:39, Darri
On 09/22/2015 07:44 AM, David Sterba wrote:
> On Fri, Sep 11, 2015 at 04:30:14PM -0400, Anna Schumaker wrote:
>> From: Zach Brown <z...@redhat.com>
>> +/*
>> + * copy_file_range() differs from regular file read and write in that it
>> + * specifically allows retu
Hi Michael,
On 09/13/2015 03:50 AM, Michael Kerrisk (man-pages) wrote:
> Hi Anna,
>
> On 09/11/2015 10:30 PM, Anna Schumaker wrote:
>> copy_file_range() is a new system call for copying ranges of data
>> completely in the kernel. This gives filesystems an opportunity to
&
Reject copies that don't have the COPY_FR_REFLINK flag set.
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
Reviewed-by: David Sterba <dste...@suse.com>
---
fs/btrfs/ioctl.c | 4
1 file changed, 4 insertions(+)
diff --git a/fs/btrfs/ioctl.c b/fs/btrfs/ioctl.c
i
error checks that should be shared.
Signed-off-by: Zach Brown <z...@redhat.com>
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
Reviewed-by: Josef Bacik <jba...@fb.com>
Reviewed-by: David Sterba <dste...@suse.com>
---
fs/btrfs/ctree.h | 3 ++
fs/btrfs/file.c
The way to think about this is that the destination filesystem reads the
data from the source file and processes it accordingly. This is
especially important to avoid an infinate loop when doing a "server to
server" copy on NFS.
Signed-off-by: Anna Schumaker <anna.schuma...@netapp
safely.
Signed-off-by: Zach Brown <z...@redhat.com>
[Anna Schumaker: Change -EINVAL to -EBADF during file verification]
[Anna Schumaker: Change flags parameter from int to unsigned int]
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
---
v3:
- Change flags parameter to ta
I still want to do an in-kernel copy even if the files are on different
mountpoints, and NFS has a "server to server" copy that expects two
files on different mountpoints. Let's have individual filesystems
implement this check instead.
Signed-off-by: Anna Schumaker <anna.schuma.
copy_file_range() is a new system call for copying ranges of data
completely in the kernel. This gives filesystems an opportunity to
implement some kind of "copy acceleration", such as reflinks or
server-side-copy (in the case of NFS).
Signed-off-by: Anna Schumaker <anna.schuma.
From: Zach Brown <z...@redhat.com>
Add sys_copy_file_range to the x86 syscall tables.
Signed-off-by: Zach Brown <z...@redhat.com>
[Anna Schumaker: Update syscall number in syscall_32.tbl]
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
---
arch/x86/entry/syscalls/
range.
Signed-off-by: Anna Schumaker <anna.schuma...@netapp.com>
---
v3:
- Check that both filesystems have the same filesystem type
- Add COPY_FR_DEDUPE flag for Darrick
- Check that at most one flag is set at a time
---
fs/read_write.c
s | 0.00s | 0.00s
system | 0.80s | 0.56s | 0.84s | 1.10s | 1.39s | 1.67s | 2.81s
cpu |41% |18% |19% |17% |17% |17% |17%
total | 1.922 | 2.990 | 4.448 | 6.292 | 7.855 | 9.480 | 15.944
Questions? Comments? Thoughts?
Anna
Anna Sc
99 matches
Mail list logo