Re: [patch 19/35] fs: icache remove redundant i_sb_list umountlocking

From: Al Viro
Date: Wed Oct 20 2010 - 09:27:26 EST


On Thu, Oct 21, 2010 at 12:03:45AM +1100, Nick Piggin wrote:

> Where can fsnotify_destroy_mark run concurrently at umount time, can you
> explain? I haven't spotted it yet.

When you destroy the group mark belongs to. Which is not tied to any
specific fs...

Basically, these marks are associated with pairs (inode, group) and
can be kicked out by either side. They pin inodes once set up, without
pinning the superblock down. Main selling point of idiotify, inherited
by fsnotify. That's why we need to go through that list on umount in
the first place - we need to evict that crap, or it'll keep inodes busy.

OTOH, removal of group also needs to kill the subset of marks - ones
belonging to that group... grep for fsnotify_put_group() and look
for the chain through fsnotify_destroy_group() and on to
fsnotify_destroy_mark() and fsnotify_destroy_inode_mark().
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/