aboutsummaryrefslogtreecommitdiffstats
path: root/fs/mount.h
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2011-12-06 12:21:54 -0500
committerAl Viro <viro@zeniv.linux.org.uk>2012-01-03 22:57:13 -0500
commit0226f4923f6c9b40cfa1c1c1b19a6ac6b3924ead (patch)
treecb0f26e6329e2222a9f3b8f85887f63980a01d37 /fs/mount.h
parent3a2393d71d77b034669d495b49c212a87e04abdc (diff)
vfs: take /proc/*/mounts and friends to fs/proc_namespace.c
rationale: that stuff is far tighter bound to fs/namespace.c than to the guts of procfs proper. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs/mount.h')
-rw-r--r--fs/mount.h24
1 files changed, 24 insertions, 0 deletions
diff --git a/fs/mount.h b/fs/mount.h
index e094c863c8af..c6e99e03350a 100644
--- a/fs/mount.h
+++ b/fs/mount.h
@@ -1,4 +1,14 @@
1#include <linux/mount.h> 1#include <linux/mount.h>
2#include <linux/seq_file.h>
3#include <linux/poll.h>
4
5struct mnt_namespace {
6 atomic_t count;
7 struct vfsmount * root;
8 struct list_head list;
9 wait_queue_head_t poll;
10 int event;
11};
2 12
3struct mnt_pcp { 13struct mnt_pcp {
4 int mnt_count; 14 int mnt_count;
@@ -49,3 +59,17 @@ static inline int mnt_has_parent(struct mount *mnt)
49} 59}
50 60
51extern struct mount *__lookup_mnt(struct vfsmount *, struct dentry *, int); 61extern struct mount *__lookup_mnt(struct vfsmount *, struct dentry *, int);
62
63static inline void get_mnt_ns(struct mnt_namespace *ns)
64{
65 atomic_inc(&ns->count);
66}
67
68struct proc_mounts {
69 struct seq_file m; /* must be the first element */
70 struct mnt_namespace *ns;
71 struct path root;
72 int (*show)(struct seq_file *, struct vfsmount *);
73};
74
75extern const struct seq_operations mounts_op;