lkml.org 
[lkml]   [2005]   [Sep]   [20]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    SubjectRe: [patch] stop inotify from sending random DELETE_SELF event under load
    From
    Date
    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 <ttb@tentacle.dhs.org>
    -
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    More majordomo info at http://vger.kernel.org/majordomo-info.html
    Please read the FAQ at http://www.tux.org/lkml/

    \
     
     \ /
      Last update: 2005-09-20 12:06    [W:4.121 / U:0.108 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site