diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2013-10-01 22:11:26 +0200 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2013-10-25 05:35:00 +0200 |
commit | 474279dc0f7745124fc76b474c8dc1294f8e87ce (patch) | |
tree | 2ad5e963e698e9524e0eabe466534f03ce324226 /fs/pnode.c | |
parent | uninline destroy_super(), consolidate alloc_super() (diff) | |
download | linux-474279dc0f7745124fc76b474c8dc1294f8e87ce.tar.xz linux-474279dc0f7745124fc76b474c8dc1294f8e87ce.zip |
split __lookup_mnt() in two functions
Instead of passing the direction as argument (and checking it on every
step through the hash chain), just have separate __lookup_mnt() and
__lookup_mnt_last(). And use the standard iterators...
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs/pnode.c')
-rw-r--r-- | fs/pnode.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/fs/pnode.c b/fs/pnode.c index 58933fd149ad..c7221bb19801 100644 --- a/fs/pnode.c +++ b/fs/pnode.c @@ -310,7 +310,7 @@ int propagate_mount_busy(struct mount *mnt, int refcnt) for (m = propagation_next(parent, parent); m; m = propagation_next(m, parent)) { - child = __lookup_mnt(&m->mnt, mnt->mnt_mountpoint, 0); + child = __lookup_mnt_last(&m->mnt, mnt->mnt_mountpoint); if (child && list_empty(&child->mnt_mounts) && (ret = do_refcount_check(child, 1))) break; @@ -332,8 +332,8 @@ static void __propagate_umount(struct mount *mnt) for (m = propagation_next(parent, parent); m; m = propagation_next(m, parent)) { - struct mount *child = __lookup_mnt(&m->mnt, - mnt->mnt_mountpoint, 0); + struct mount *child = __lookup_mnt_last(&m->mnt, + mnt->mnt_mountpoint); /* * umount the child only if the child has no * other children |