Re: [RFC] guarantee inode of alias's parent

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

 



On Fri, Jul 07, 2017 at 03:28:11PM +0200, Gioh Kim wrote:

> Before __d_unalias(), the dentry and parent of the dentry
> are locked. But I wonder how I can assure of existence of the
> alias and the parent of the alias.
> 
> Where is the code to lock alias and alias->d_parent?

Nowhere.  Why the hell would you want to lock them?

> What will happend if alias->d_parent be deleted by another process?

Huh?  As soon as you've grabbed ->s_vfs_rename_mutex, ->d_parent of everything on
that filesystem is stable - and positive.  Moreover, any positive dentry with
references held (in particular, anyone's parent) is going to remain such for
as long as those references are held.



[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