diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2009-04-18 03:28:19 -0400 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2009-06-11 21:36:01 -0400 |
commit | 589ff870ed60a9ebdd5ec99ec3f5afe1282fe151 (patch) | |
tree | a628f8db3bd587df6e2a918216aa64946b506e6f | |
parent | bab77ebf51e3902f608ecf08c9d34a0a52ac35a9 (diff) |
Switch collect_mounts() to struct path
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
-rw-r--r-- | fs/namespace.c | 4 | ||||
-rw-r--r-- | include/linux/fs.h | 2 | ||||
-rw-r--r-- | kernel/audit_tree.c | 6 |
3 files changed, 6 insertions, 6 deletions
diff --git a/fs/namespace.c b/fs/namespace.c index 88a904d5aa23..c85962206aad 100644 --- a/fs/namespace.c +++ b/fs/namespace.c | |||
@@ -1253,11 +1253,11 @@ Enomem: | |||
1253 | return NULL; | 1253 | return NULL; |
1254 | } | 1254 | } |
1255 | 1255 | ||
1256 | struct vfsmount *collect_mounts(struct vfsmount *mnt, struct dentry *dentry) | 1256 | struct vfsmount *collect_mounts(struct path *path) |
1257 | { | 1257 | { |
1258 | struct vfsmount *tree; | 1258 | struct vfsmount *tree; |
1259 | down_write(&namespace_sem); | 1259 | down_write(&namespace_sem); |
1260 | tree = copy_tree(mnt, dentry, CL_COPY_ALL | CL_PRIVATE); | 1260 | tree = copy_tree(path->mnt, path->dentry, CL_COPY_ALL | CL_PRIVATE); |
1261 | up_write(&namespace_sem); | 1261 | up_write(&namespace_sem); |
1262 | return tree; | 1262 | return tree; |
1263 | } | 1263 | } |
diff --git a/include/linux/fs.h b/include/linux/fs.h index 323b5ce474c1..03fb2102b8f3 100644 --- a/include/linux/fs.h +++ b/include/linux/fs.h | |||
@@ -1800,7 +1800,7 @@ extern struct vfsmount *kern_mount_data(struct file_system_type *, void *data); | |||
1800 | extern int may_umount_tree(struct vfsmount *); | 1800 | extern int may_umount_tree(struct vfsmount *); |
1801 | extern int may_umount(struct vfsmount *); | 1801 | extern int may_umount(struct vfsmount *); |
1802 | extern long do_mount(char *, char *, char *, unsigned long, void *); | 1802 | extern long do_mount(char *, char *, char *, unsigned long, void *); |
1803 | extern struct vfsmount *collect_mounts(struct vfsmount *, struct dentry *); | 1803 | extern struct vfsmount *collect_mounts(struct path *); |
1804 | extern void drop_collected_mounts(struct vfsmount *); | 1804 | extern void drop_collected_mounts(struct vfsmount *); |
1805 | 1805 | ||
1806 | extern int vfs_statfs(struct dentry *, struct kstatfs *); | 1806 | extern int vfs_statfs(struct dentry *, struct kstatfs *); |
diff --git a/kernel/audit_tree.c b/kernel/audit_tree.c index 6e7351739a82..1f6396d76687 100644 --- a/kernel/audit_tree.c +++ b/kernel/audit_tree.c | |||
@@ -568,7 +568,7 @@ void audit_trim_trees(void) | |||
568 | if (err) | 568 | if (err) |
569 | goto skip_it; | 569 | goto skip_it; |
570 | 570 | ||
571 | root_mnt = collect_mounts(path.mnt, path.dentry); | 571 | root_mnt = collect_mounts(&path); |
572 | path_put(&path); | 572 | path_put(&path); |
573 | if (!root_mnt) | 573 | if (!root_mnt) |
574 | goto skip_it; | 574 | goto skip_it; |
@@ -660,7 +660,7 @@ int audit_add_tree_rule(struct audit_krule *rule) | |||
660 | err = kern_path(tree->pathname, 0, &path); | 660 | err = kern_path(tree->pathname, 0, &path); |
661 | if (err) | 661 | if (err) |
662 | goto Err; | 662 | goto Err; |
663 | mnt = collect_mounts(path.mnt, path.dentry); | 663 | mnt = collect_mounts(&path); |
664 | path_put(&path); | 664 | path_put(&path); |
665 | if (!mnt) { | 665 | if (!mnt) { |
666 | err = -ENOMEM; | 666 | err = -ENOMEM; |
@@ -720,7 +720,7 @@ int audit_tag_tree(char *old, char *new) | |||
720 | err = kern_path(new, 0, &path); | 720 | err = kern_path(new, 0, &path); |
721 | if (err) | 721 | if (err) |
722 | return err; | 722 | return err; |
723 | tagged = collect_mounts(path.mnt, path.dentry); | 723 | tagged = collect_mounts(&path); |
724 | path_put(&path); | 724 | path_put(&path); |
725 | if (!tagged) | 725 | if (!tagged) |
726 | return -ENOMEM; | 726 | return -ENOMEM; |