]> git.baikalelectronics.ru Git - kernel.git/commit
fix loop checks in d_materialise_unique()
authorAl Viro <viro@zeniv.linux.org.uk>
Wed, 13 Jul 2011 01:42:24 +0000 (21:42 -0400)
committerAl Viro <viro@zeniv.linux.org.uk>
Fri, 15 Jul 2011 01:33:41 +0000 (21:33 -0400)
commit2b36f9bac79b6cee4e3cc335947ac6e55956cca7
tree3c0cb24361ccfb460b93b0fd6385650df80a26e6
parent0a1962d872dfb45f4da74ca392dd6700afa05892
fix loop checks in d_materialise_unique()

Both __d_unalias() and __d_materialise_dentry() need loop prevention.
Grab rename_lock in caller, check for loops there...

As a side benefit, we have dentry_lock_for_move() called only under
rename_lock, which seriously reduces deadlock potential of the
execrable "locking order" used for ->d_lock.

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
fs/dcache.c