diff options
author | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2018-10-08 15:43:12 +0200 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2018-10-08 15:43:12 +0200 |
commit | 4e1a606d552de03aec2b1fd157011bf012fcc870 (patch) | |
tree | 7d7683fc2d5286a36782df572f475abb3bb2e173 /fs/read_write.c | |
parent | TTY: sn_console: Replace spin_is_locked() with spin_trylock() (diff) | |
parent | Linux 4.19-rc7 (diff) | |
download | linux-4e1a606d552de03aec2b1fd157011bf012fcc870.tar.xz linux-4e1a606d552de03aec2b1fd157011bf012fcc870.zip |
Merge 4.19-rc7 into tty-next
We want the fixes in here as well.
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'fs/read_write.c')
-rw-r--r-- | fs/read_write.c | 17 |
1 files changed, 15 insertions, 2 deletions
diff --git a/fs/read_write.c b/fs/read_write.c index 39b4a21dd933..8a2737f0d61d 100644 --- a/fs/read_write.c +++ b/fs/read_write.c @@ -1818,8 +1818,8 @@ int vfs_clone_file_prep_inodes(struct inode *inode_in, loff_t pos_in, } EXPORT_SYMBOL(vfs_clone_file_prep_inodes); -int vfs_clone_file_range(struct file *file_in, loff_t pos_in, - struct file *file_out, loff_t pos_out, u64 len) +int do_clone_file_range(struct file *file_in, loff_t pos_in, + struct file *file_out, loff_t pos_out, u64 len) { struct inode *inode_in = file_inode(file_in); struct inode *inode_out = file_inode(file_out); @@ -1866,6 +1866,19 @@ int vfs_clone_file_range(struct file *file_in, loff_t pos_in, return ret; } +EXPORT_SYMBOL(do_clone_file_range); + +int vfs_clone_file_range(struct file *file_in, loff_t pos_in, + struct file *file_out, loff_t pos_out, u64 len) +{ + int ret; + + file_start_write(file_out); + ret = do_clone_file_range(file_in, pos_in, file_out, pos_out, len); + file_end_write(file_out); + + return ret; +} EXPORT_SYMBOL(vfs_clone_file_range); /* |