]> err.no Git - linux-2.6/commit
[PATCH] r/o bind mounts: clean up OCFS2 nlink handling
authorMark Fasheh <mark.fasheh@oracle.com>
Sun, 1 Oct 2006 06:29:05 +0000 (23:29 -0700)
committerLinus Torvalds <torvalds@g5.osdl.org>
Sun, 1 Oct 2006 07:39:30 +0000 (00:39 -0700)
commit17ff785691503f63ec648df82a7fdaece7695561
tree9777f4787253941c723aac1e13ab37fb285bcc4a
parentd8c76e6f45c111c32a4b3e50a2adc9210737b0d8
[PATCH] r/o bind mounts: clean up OCFS2 nlink handling

OCFS2 does some operations on i_nlink, then reverts them if some of its
operations fail to complete.  This does not fit in well with the
drop_nlink() logic where we expect i_nlink to stay at zero once it gets
there.

So, delay all of the nlink operations until we're sure that the operations
have completed.  Also, introduce a small helper to check whether an inode
has proper "unlinkable" i_nlink counts no matter whether it is a directory
or regular inode.

This patch is broken out from the others because it does contain some
logical changes.

Signed-off-by: Dave Hansen <haveblue@us.ibm.com>
Signed-off-by: Mark Fasheh <mark.fasheh@oracle.com>
Cc: Christoph Hellwig <hch@lst.de>
Cc: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
fs/ocfs2/namei.c