diff options
author | Kirill Korotaev <dev@sw.ru> | 2006-12-08 05:37:56 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.osdl.org> | 2006-12-08 11:28:51 -0500 |
commit | 6b3286ed1169d74fea401367d6d4d6c6ec758a81 (patch) | |
tree | faf5beddb797875bb92855f8606735478267959a /include/linux/namespace.h | |
parent | 1ec320afdc9552c92191d5f89fcd1ebe588334ca (diff) |
[PATCH] rename struct namespace to struct mnt_namespace
Rename 'struct namespace' to 'struct mnt_namespace' to avoid confusion with
other namespaces being developped for the containers : pid, uts, ipc, etc.
'namespace' variables and attributes are also renamed to 'mnt_ns'
Signed-off-by: Kirill Korotaev <dev@sw.ru>
Signed-off-by: Cedric Le Goater <clg@fr.ibm.com>
Cc: Eric W. Biederman <ebiederm@xmission.com>
Cc: Herbert Poetzl <herbert@13thfloor.at>
Cc: Sukadev Bhattiprolu <sukadev@us.ibm.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'include/linux/namespace.h')
-rw-r--r-- | include/linux/namespace.h | 42 |
1 files changed, 0 insertions, 42 deletions
diff --git a/include/linux/namespace.h b/include/linux/namespace.h deleted file mode 100644 index d137009f0b2b..000000000000 --- a/include/linux/namespace.h +++ /dev/null | |||
@@ -1,42 +0,0 @@ | |||
1 | #ifndef _NAMESPACE_H_ | ||
2 | #define _NAMESPACE_H_ | ||
3 | #ifdef __KERNEL__ | ||
4 | |||
5 | #include <linux/mount.h> | ||
6 | #include <linux/sched.h> | ||
7 | #include <linux/nsproxy.h> | ||
8 | |||
9 | struct namespace { | ||
10 | atomic_t count; | ||
11 | struct vfsmount * root; | ||
12 | struct list_head list; | ||
13 | wait_queue_head_t poll; | ||
14 | int event; | ||
15 | }; | ||
16 | |||
17 | extern int copy_namespace(int, struct task_struct *); | ||
18 | extern void __put_namespace(struct namespace *namespace); | ||
19 | extern struct namespace *dup_namespace(struct task_struct *, struct fs_struct *); | ||
20 | |||
21 | static inline void put_namespace(struct namespace *namespace) | ||
22 | { | ||
23 | if (atomic_dec_and_lock(&namespace->count, &vfsmount_lock)) | ||
24 | /* releases vfsmount_lock */ | ||
25 | __put_namespace(namespace); | ||
26 | } | ||
27 | |||
28 | static inline void exit_namespace(struct task_struct *p) | ||
29 | { | ||
30 | struct namespace *namespace = p->nsproxy->namespace; | ||
31 | if (namespace) { | ||
32 | put_namespace(namespace); | ||
33 | } | ||
34 | } | ||
35 | |||
36 | static inline void get_namespace(struct namespace *namespace) | ||
37 | { | ||
38 | atomic_inc(&namespace->count); | ||
39 | } | ||
40 | |||
41 | #endif | ||
42 | #endif | ||