|
@@ -333,7 +333,7 @@ static struct dentry *autofs4_expire_indirect(struct super_block *sb,
|
|
/* Can we expire this guy */
|
|
/* Can we expire this guy */
|
|
if (autofs4_can_expire(dentry, timeout, do_now)) {
|
|
if (autofs4_can_expire(dentry, timeout, do_now)) {
|
|
expired = dentry;
|
|
expired = dentry;
|
|
- break;
|
|
|
|
|
|
+ goto found;
|
|
}
|
|
}
|
|
goto next;
|
|
goto next;
|
|
}
|
|
}
|
|
@@ -352,7 +352,7 @@ static struct dentry *autofs4_expire_indirect(struct super_block *sb,
|
|
inf->flags |= AUTOFS_INF_EXPIRING;
|
|
inf->flags |= AUTOFS_INF_EXPIRING;
|
|
spin_unlock(&sbi->fs_lock);
|
|
spin_unlock(&sbi->fs_lock);
|
|
expired = dentry;
|
|
expired = dentry;
|
|
- break;
|
|
|
|
|
|
+ goto found;
|
|
}
|
|
}
|
|
spin_unlock(&sbi->fs_lock);
|
|
spin_unlock(&sbi->fs_lock);
|
|
/*
|
|
/*
|
|
@@ -363,7 +363,7 @@ static struct dentry *autofs4_expire_indirect(struct super_block *sb,
|
|
expired = autofs4_check_leaves(mnt, dentry, timeout, do_now);
|
|
expired = autofs4_check_leaves(mnt, dentry, timeout, do_now);
|
|
if (expired) {
|
|
if (expired) {
|
|
dput(dentry);
|
|
dput(dentry);
|
|
- break;
|
|
|
|
|
|
+ goto found;
|
|
}
|
|
}
|
|
}
|
|
}
|
|
next:
|
|
next:
|
|
@@ -371,18 +371,16 @@ next:
|
|
spin_lock(&dcache_lock);
|
|
spin_lock(&dcache_lock);
|
|
next = next->next;
|
|
next = next->next;
|
|
}
|
|
}
|
|
-
|
|
|
|
- if (expired) {
|
|
|
|
- DPRINTK("returning %p %.*s",
|
|
|
|
- expired, (int)expired->d_name.len, expired->d_name.name);
|
|
|
|
- spin_lock(&dcache_lock);
|
|
|
|
- list_move(&expired->d_parent->d_subdirs, &expired->d_u.d_child);
|
|
|
|
- spin_unlock(&dcache_lock);
|
|
|
|
- return expired;
|
|
|
|
- }
|
|
|
|
spin_unlock(&dcache_lock);
|
|
spin_unlock(&dcache_lock);
|
|
-
|
|
|
|
return NULL;
|
|
return NULL;
|
|
|
|
+
|
|
|
|
+found:
|
|
|
|
+ DPRINTK("returning %p %.*s",
|
|
|
|
+ expired, (int)expired->d_name.len, expired->d_name.name);
|
|
|
|
+ spin_lock(&dcache_lock);
|
|
|
|
+ list_move(&expired->d_parent->d_subdirs, &expired->d_u.d_child);
|
|
|
|
+ spin_unlock(&dcache_lock);
|
|
|
|
+ return expired;
|
|
}
|
|
}
|
|
|
|
|
|
/* Perform an expiry operation */
|
|
/* Perform an expiry operation */
|