Re: [RFC][PATCH] fix breakage caused by d_find_alias() semantics change

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

 



On Sun, May 13, 2018 at 11:35:15AM -0700, Linus Torvalds wrote:
> On Sun, May 13, 2018 at 9:18 AM Al Viro <viro@xxxxxxxxxxxxxxxxxx> wrote:
> 
> >                          /* Called from selinux_complete_init, try to find
> a dentry. */
> >                          dentry = d_find_alias(inode);
> > +                       if (!dentry)
> > +                               dentry = d_find_any_alias(inode);
> 
> Can you please explain why this isn't just
> 
>          dentry = d_find_any_alias(inode);
> 
> without the initial "try to find a hashed alias"?

The whole reason why that thing is getting a dentry is that some filesystems
really want a *connected* dentry for getxattr.  Sure, saner ones will be
happy with disconnected dentry, but...

If you want to rearchitect the shitpile under security/* so that it would
not rely upon accidental properties of filesystems, you are welcome to that
and to the resulting psychiatrist bills ;-/



[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