Commit e8462caa authored by Akinobu Mita's avatar Akinobu Mita Committed by Linus Torvalds

fs: use hlist_unhashed

Use hlist_unhashed() instead of opencoded equivalent.
Signed-off-by: default avatarAkinobu Mita <akinobu.mita@gmail.com>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 07a154b2
...@@ -89,7 +89,7 @@ static void d_free(struct dentry *dentry) ...@@ -89,7 +89,7 @@ static void d_free(struct dentry *dentry)
if (dentry->d_op && dentry->d_op->d_release) if (dentry->d_op && dentry->d_op->d_release)
dentry->d_op->d_release(dentry); dentry->d_op->d_release(dentry);
/* if dentry was never inserted into hash, immediate free is OK */ /* if dentry was never inserted into hash, immediate free is OK */
if (dentry->d_hash.pprev == NULL) if (hlist_unhashed(&dentry->d_hash))
__d_free(dentry); __d_free(dentry);
else else
call_rcu(&dentry->d_u.d_rcu, d_callback); call_rcu(&dentry->d_u.d_rcu, d_callback);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment