projects
/
linux-2.6-block.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
autofs4: eliminate d_unhashed in path walk checks
[linux-2.6-block.git]
/
fs
/
autofs4
/
root.c
diff --git
a/fs/autofs4/root.c
b/fs/autofs4/root.c
index 81700f4a19da53b04460503a19e07618528e83e3..b6530f321adbb76294753a3c5a80e51ff7f1caad 100644
(file)
--- a/
fs/autofs4/root.c
+++ b/
fs/autofs4/root.c
@@
-133,7
+133,7
@@
static int autofs4_dir_open(struct inode *inode, struct file *file)
* it.
*/
spin_lock(&dcache_lock);
* it.
*/
spin_lock(&dcache_lock);
- if (!d_mountpoint(dentry) &&
__simple_empty(dentry
)) {
+ if (!d_mountpoint(dentry) &&
list_empty(&dentry->d_subdirs
)) {
spin_unlock(&dcache_lock);
return -ENOENT;
}
spin_unlock(&dcache_lock);
return -ENOENT;
}
@@
-257,7
+257,7
@@
static void *autofs4_follow_link(struct dentry *dentry, struct nameidata *nd)
* mount it again.
*/
if (ino->flags & AUTOFS_INF_PENDING ||
* mount it again.
*/
if (ino->flags & AUTOFS_INF_PENDING ||
- (!d_mountpoint(dentry) &&
__simple_empty(dentry
))) {
+ (!d_mountpoint(dentry) &&
list_empty(&dentry->d_subdirs
))) {
spin_unlock(&dcache_lock);
spin_unlock(&sbi->fs_lock);
spin_unlock(&dcache_lock);
spin_unlock(&sbi->fs_lock);
@@
-340,8
+340,7
@@
static int autofs4_revalidate(struct dentry *dentry, struct nameidata *nd)
/* Check for a non-mountpoint directory with no contents */
spin_lock(&dcache_lock);
if (S_ISDIR(dentry->d_inode->i_mode) &&
/* Check for a non-mountpoint directory with no contents */
spin_lock(&dcache_lock);
if (S_ISDIR(dentry->d_inode->i_mode) &&
- !d_mountpoint(dentry) &&
- __simple_empty(dentry)) {
+ !d_mountpoint(dentry) && list_empty(&dentry->d_subdirs)) {
DPRINTK("dentry=%p %.*s, emptydir",
dentry, dentry->d_name.len, dentry->d_name.name);
spin_unlock(&dcache_lock);
DPRINTK("dentry=%p %.*s, emptydir",
dentry, dentry->d_name.len, dentry->d_name.name);
spin_unlock(&dcache_lock);