summaryrefslogtreecommitdiffstats
path: root/include/linux/proc_ns.h
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2014-11-01 03:13:17 -0400
committerAl Viro <viro@zeniv.linux.org.uk>2014-12-04 14:34:54 -0500
commitf77c80142e1afe6d5c16975ca5d7d1fc324b16f9 (patch)
treec2c8f726402610aee77ccca0627a4c38f944640b /include/linux/proc_ns.h
parent33c429405a2c8d9e42afb9fee88a63cfb2de1e98 (diff)
downloadop-kernel-dev-f77c80142e1afe6d5c16975ca5d7d1fc324b16f9.zip
op-kernel-dev-f77c80142e1afe6d5c16975ca5d7d1fc324b16f9.tar.gz
bury struct proc_ns in fs/proc
a) make get_proc_ns() return a pointer to struct ns_common b) mirror ns_ops in dentry->d_fsdata of ns dentries, so that is_mnt_ns_file() could get away with fewer dereferences. That way struct proc_ns becomes invisible outside of fs/proc/*.c Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'include/linux/proc_ns.h')
-rw-r--r--include/linux/proc_ns.h9
1 files changed, 2 insertions, 7 deletions
diff --git a/include/linux/proc_ns.h b/include/linux/proc_ns.h
index f5780ee..2837ff4 100644
--- a/include/linux/proc_ns.h
+++ b/include/linux/proc_ns.h
@@ -16,11 +16,6 @@ struct proc_ns_operations {
int (*install)(struct nsproxy *nsproxy, struct ns_common *ns);
};
-struct proc_ns {
- struct ns_common *ns;
- const struct proc_ns_operations *ns_ops;
-};
-
extern const struct proc_ns_operations netns_operations;
extern const struct proc_ns_operations utsns_operations;
extern const struct proc_ns_operations ipcns_operations;
@@ -44,7 +39,7 @@ enum {
extern int pid_ns_prepare_proc(struct pid_namespace *ns);
extern void pid_ns_release_proc(struct pid_namespace *ns);
extern struct file *proc_ns_fget(int fd);
-extern struct proc_ns *get_proc_ns(struct inode *);
+extern struct ns_common *get_proc_ns(struct inode *);
extern int proc_alloc_inum(unsigned int *pino);
extern void proc_free_inum(unsigned int inum);
extern bool proc_ns_inode(struct inode *inode);
@@ -59,7 +54,7 @@ static inline struct file *proc_ns_fget(int fd)
return ERR_PTR(-EINVAL);
}
-static inline struct proc_ns *get_proc_ns(struct inode *inode) { return NULL; }
+static inline struct ns_common *get_proc_ns(struct inode *inode) { return NULL; }
static inline int proc_alloc_inum(unsigned int *inum)
{
OpenPOWER on IntegriCloud