Re: [PATCH -v3 7/8] fsnotify: add in inode fsnotify markings

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Eric Paris
Date: Friday, November 28, 2008 - 4:43 pm

On Fri, 2008-11-28 at 05:42 +0000, Al Viro wrote:

fsnotify_mark_get() can only find this object through either the
entry->i_list or entry->g_list.  When we drop our ref to 0 and hold the
spinlock we know that no other task would have been able to find us on
those lists (everything that searches the i_list holds the
i_fsnotify_lock and that lock was dropped since we cleared ourselves
from that list and the same is true for the lock on the g_list side)

So if kill_me is set and the refcnt == 0 we are not on either list and
no other task could find this to try to call mark_get().   I'll review
it to make sure, but the design is that we are safe since nothing else
can find us to increment the ref cnt.

I'll review.

--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[PATCH -v3 6/8] fsnotify: add group priorities, Eric Paris, (Tue Nov 25, 10:21 am)
Re: [PATCH -v3 6/8] fsnotify: add group priorities, Peter Zijlstra, (Thu Nov 27, 9:25 am)
Re: [PATCH -v3 3/8] fsnotify: sys_execve and sys_uselib do ..., Christoph Hellwig, (Fri Nov 28, 3:16 am)
Re: [PATCH -v3 7/8] fsnotify: add in inode fsnotify markings, Eric Paris, (Fri Nov 28, 4:43 pm)
Re: [PATCH -v3 6/8] fsnotify: add group priorities, Eric Paris, (Mon Dec 1, 8:20 am)
Re: [PATCH -v3 6/8] fsnotify: add group priorities, Peter Zijlstra, (Mon Dec 1, 8:37 am)