summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2014-09-24 21:27:39 +0200
committerAl Viro <viro@zeniv.linux.org.uk>2014-09-27 21:59:11 +0200
commita28ddb87cdddb0db57466ba7f59f831002f4340c (patch)
tree856486ca1e8fade63932ea1d14b82ae5a04d9af1
parentfold unlocking the children into dentry_unlock_parents_for_move() (diff)
downloadlinux-a28ddb87cdddb0db57466ba7f59f831002f4340c.tar.xz
linux-a28ddb87cdddb0db57466ba7f59f831002f4340c.zip
fold swapping ->d_name.hash into switch_names()
and do it along with ->d_name.len there Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
-rw-r--r--fs/dcache.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/fs/dcache.c b/fs/dcache.c
index 92f7d76db498..7599d35b4ae5 100644
--- a/fs/dcache.c
+++ b/fs/dcache.c
@@ -2412,7 +2412,7 @@ static void switch_names(struct dentry *dentry, struct dentry *target)
}
}
}
- swap(dentry->d_name.len, target->d_name.len);
+ swap(dentry->d_name.hash_len, target->d_name.hash_len);
}
static void dentry_lock_for_move(struct dentry *dentry, struct dentry *target)
@@ -2510,7 +2510,6 @@ static void __d_move(struct dentry *dentry, struct dentry *target,
/* Switch the names.. */
switch_names(dentry, target);
- swap(dentry->d_name.hash, target->d_name.hash);
/* ... and switch them in the tree */
if (IS_ROOT(dentry)) {