vfs: Add vfs_copy_file_range() support for pagecache copies
authorAnna Schumaker <Anna.Schumaker@netapp.com>
Tue, 10 Nov 2015 21:53:33 +0000 (16:53 -0500)
committerAl Viro <viro@zeniv.linux.org.uk>
Tue, 1 Dec 2015 19:00:55 +0000 (14:00 -0500)
commiteac70053a141998c40907747d6cea1d53a9414be
tree67b51897837e7e031727afd38596e9d5eb10e196
parent3db11b2eecc02dc0eee943e71822c6d929281aa7
vfs: Add vfs_copy_file_range() support for pagecache copies

This allows us to have an in-kernel copy mechanism that avoids frequent
switches between kernel and user space.  This is especially useful so
NFSD can support server-side copies.

The default (flags=0) means to first attempt copy acceleration, but use
the pagecache if that fails.

Signed-off-by: Anna Schumaker <Anna.Schumaker@Netapp.com>
Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com>
Reviewed-by: Padraig Brady <P@draigBrady.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
fs/read_write.c