Re: [PATCH 4/7] proc: Use d_invalidate in proc_prune_siblings_dcache

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

 



Al Viro <viro@xxxxxxxxxxxxxxxxxx> writes:

> On Thu, Feb 20, 2020 at 10:54:20PM +0000, Al Viro wrote:
>> On Thu, Feb 20, 2020 at 02:49:53PM -0600, Eric W. Biederman wrote:
>> > 
>> > The function d_prune_aliases has the problem that it will only prune
>> > aliases thare are completely unused.  It will not remove aliases for
>> > the dcache or even think of removing mounts from the dcache.  For that
>> > behavior d_invalidate is needed.
>> > 
>> > To use d_invalidate replace d_prune_aliases with d_find_alias
>> > followed by d_invalidate and dput.  This is safe and complete
>> > because no inode in proc has any hardlinks or aliases.
>> 
>> s/no inode.*/it's a fucking directory inode./
>
> Wait... You are using it for sysctls as well?  Ho-hum...  The thing is,
> for sysctls you are likely to run into consequent entries with the
> same superblock, making for a big pile of useless playing with
> ->s_active...  And yes, that applied to mainline as well

Which is why I worked to merge the two cases since they were so close.
Fewer things to fix and more eyeballs on the code.

Eric





[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