回复:[RFC PATCH 1/2] ovl: skip checking lower file's write permisson on truncate

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

 



 ---- 在 星期六, 2021-04-24 22:03:15 Chengguang Xu <cgxu519@xxxxxxxxxxxx> 撰写 ----
 > Lower files may be shared in overlayfs so strictly checking write
 > perssmion on lower file will cause interferes between different
 > overlayfs instances.

Any comment for this?

Thanks,
Chengguang



 > 
 > Signed-off-by: Chengguang Xu <cgxu519@xxxxxxxxxxxx>
 > ---
 >  fs/overlayfs/inode.c | 6 ------
 >  1 file changed, 6 deletions(-)
 > 
 > diff --git a/fs/overlayfs/inode.c b/fs/overlayfs/inode.c
 > index 28c71978eb2e..17d1add0af1a 100644
 > --- a/fs/overlayfs/inode.c
 > +++ b/fs/overlayfs/inode.c
 > @@ -31,12 +31,6 @@ int ovl_setattr(struct user_namespace *mnt_userns, struct dentry *dentry,
 >          goto out;
 >  
 >      if (attr->ia_valid & ATTR_SIZE) {
 > -        struct inode *realinode = d_inode(ovl_dentry_real(dentry));
 > -
 > -        err = -ETXTBSY;
 > -        if (atomic_read(&realinode->i_writecount) < 0)
 > -            goto out_drop_write;
 > -
 >          /* Truncate should trigger data copy up as well */
 >          full_copy_up = true;
 >      }
 > -- 
 > 2.27.0
 > 
 > 
 > 




[Index of Archives]     [Linux Filesystems Devel]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux