Re: [patch] stop inotify from sending random DELETE_SELF event under load

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

 



On Mon, 2005-09-19 at 21:03 -0700, Linus Torvalds wrote:
> 
> On Mon, 19 Sep 2005, John McCutchan wrote:
> > 
> > I think the name fsnotify_inoderemove is causing some confusion. We only
> > care that some name that is pointing to this inode has been deleted. 
> > Remember, it was suggested as a replacement for fsnotify_unlink. We
> > don't care if the inode is actually going away or not. 
> 
> Ahh. 
> 
> Well, the problem is one of ordering. You could do it unconditionally at 
> the top of d_delete(). If that's ok, then good.
> 
> The problem with that is that the name will still be available for a while 
> afterwards - another process could look it up on another CPU.
> 
> And the _name_ won't be gone until after we've already dropped the inode.  
> Remember? You got oopses because you were trying to access an inode that
> simply didn't exist any more..
> 
> That's where "dentry_iput()" comes in. It's after you've removed the name, 
> but before the inode is gone. However, then you do end up having the 
> problem that you can't tell a delete from a "drop the dcache entry" any 
> more.

Yep, that sums it up. The new patch looks good, I will have it tested.

-- 
John McCutchan <[email protected]>
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]
  Powered by Linux