projects
/
platform
/
kernel
/
linux-amlogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
469796d
)
sysfs: just use d_materialise_unique()
author
Al Viro
<viro@zeniv.linux.org.uk>
Fri, 8 Jun 2012 00:56:54 +0000
(20:56 -0400)
committer
Al Viro
<viro@zeniv.linux.org.uk>
Sat, 14 Jul 2012 12:35:12 +0000
(16:35 +0400)
same as for nfs et.al.
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
fs/sysfs/dir.c
patch
|
blob
|
history
diff --git
a/fs/sysfs/dir.c
b/fs/sysfs/dir.c
index
77c44ce
..
a5cf784
100644
(file)
--- a/
fs/sysfs/dir.c
+++ b/
fs/sysfs/dir.c
@@
-793,14
+793,7
@@
static struct dentry * sysfs_lookup(struct inode *dir, struct dentry *dentry,
}
/* instantiate and hash dentry */
- ret = d_find_alias(inode);
- if (!ret) {
- d_add(dentry, inode);
- } else {
- d_move(ret, dentry);
- iput(inode);
- }
-
+ ret = d_materialise_unique(dentry, inode);
out_unlock:
mutex_unlock(&sysfs_mutex);
return ret;