Re: [PATCH] vfs: fix vfs_clone_file_range() for overlayfs files

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Oct 28, 2016 at 6:25 PM, Amir Goldstein <amir73il@xxxxxxxxx> wrote:
> On Fri, Oct 28, 2016 at 5:25 PM, Miklos Szeredi <miklos@xxxxxxxxxx> wrote:
>> On Wed, Oct 26, 2016 at 9:34 PM, Amir Goldstein <amir73il@xxxxxxxxx> wrote:
>>> With overlayfs, it is wrong to compare file_inode(inode)->i_sb
>>> of regular files with those of non-regular files, because the
>>> former reference the real (upper/lower) sb and the latter reference
>>> the overlayfs sb.
>>>
>>> Move the test for same super block after the sanity tests for
>>> clone range of directory and non-regular file.
>>
>> Better:  compare ->f_path.dentry->d_sb instead of file_inode()->i_sb.
>> We don't want to be mixing files that come from overlayfs and ones
>> that come from the underlying layers.
>
> That's not a good option.
> When source file is in lower and dest file is in upper, then clone range
> should go forward iff both lower and upper inodes are on the same sb.
> The test as it is checks for this properly.
>

Ping.

Do you have any more question about this change?
Do you mind queuing this up for next along with the rest of the
clone_file_range() changes?

It'd be nice to have all xfstests pass for overlayfs on 4.10...

>>
>> BTW, would it be worthwhile adding clone_file_range() support to overlayfs?
>>
>
> There is nothing to add. It works quite well because clone_file_range works
> on inode level. In fact, the entire 'clone' group of xfstests passes
> with overlayfs
> of lower and upper on the same XFS filesystem (with reflink support).
>
> Amir.
--
To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [Samba]     [Device Mapper]     [CEPH Development]
  Powered by Linux