On Mon, Sep 23, 2019 at 11:32:43AM +0800, zhengbin (A) wrote: > > Is it possible to trigger ABBA deadlock? In next_positive, the lock order is (parent, dentry), > > while in dput, the lock order is (dentry, parent). Cause we use spin_trylock(parent), so the ABBA deadlock will not open. > > dput > > fast_dput > > spin_lock(&dentry->d_lock) > > dentry_kill > > spin_trylock(&parent->d_lock)) > > Is there any other scene like dput, but do not use spin_trylock? I am looking for the code, till now do not find this There should be none. The order is parent, then child. And all changes of the tree topology are serialized by rename_lock.