diff options
author | Serge E. Hallyn <serue@us.ibm.com> | 2009-04-06 22:01:08 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2009-04-07 11:31:09 -0400 |
commit | 614b84cf4e4a920d2af32b8f147ea1e3b8c27ea6 (patch) | |
tree | 52478e38cd400042bd89f123c4101c95943ae492 /ipc/util.h | |
parent | 909e6d94795654040ed416ac69858d5d2ce66dd3 (diff) |
namespaces: mqueue ns: move mqueue_mnt into struct ipc_namespace
Move mqueue vfsmount plus a few tunables into the ipc_namespace struct.
The CONFIG_IPC_NS boolean and the ipc_namespace struct will serve both the
posix message queue namespaces and the SYSV ipc namespaces.
The sysctl code will be fixed separately in patch 3. After just this
patch, making a change to posix mqueue tunables always changes the values
in the initial ipc namespace.
Signed-off-by: Cedric Le Goater <clg@fr.ibm.com>
Signed-off-by: Serge E. Hallyn <serue@us.ibm.com>
Cc: Alexey Dobriyan <adobriyan@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'ipc/util.h')
-rw-r--r-- | ipc/util.h | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/ipc/util.h b/ipc/util.h index 3646b45a03c9..0e7d9223acc1 100644 --- a/ipc/util.h +++ b/ipc/util.h | |||
@@ -20,6 +20,13 @@ void shm_init (void); | |||
20 | 20 | ||
21 | struct ipc_namespace; | 21 | struct ipc_namespace; |
22 | 22 | ||
23 | #ifdef CONFIG_POSIX_MQUEUE | ||
24 | void mq_exit_ns(struct ipc_namespace *ns); | ||
25 | #else | ||
26 | static inline void mq_exit_ns(struct ipc_namespace *ns) { } | ||
27 | #endif | ||
28 | |||
29 | #ifdef CONFIG_SYSVIPC | ||
23 | void sem_init_ns(struct ipc_namespace *ns); | 30 | void sem_init_ns(struct ipc_namespace *ns); |
24 | void msg_init_ns(struct ipc_namespace *ns); | 31 | void msg_init_ns(struct ipc_namespace *ns); |
25 | void shm_init_ns(struct ipc_namespace *ns); | 32 | void shm_init_ns(struct ipc_namespace *ns); |
@@ -27,6 +34,15 @@ void shm_init_ns(struct ipc_namespace *ns); | |||
27 | void sem_exit_ns(struct ipc_namespace *ns); | 34 | void sem_exit_ns(struct ipc_namespace *ns); |
28 | void msg_exit_ns(struct ipc_namespace *ns); | 35 | void msg_exit_ns(struct ipc_namespace *ns); |
29 | void shm_exit_ns(struct ipc_namespace *ns); | 36 | void shm_exit_ns(struct ipc_namespace *ns); |
37 | #else | ||
38 | static inline void sem_init_ns(struct ipc_namespace *ns) { } | ||
39 | static inline void msg_init_ns(struct ipc_namespace *ns) { } | ||
40 | static inline void shm_init_ns(struct ipc_namespace *ns) { } | ||
41 | |||
42 | static inline void sem_exit_ns(struct ipc_namespace *ns) { } | ||
43 | static inline void msg_exit_ns(struct ipc_namespace *ns) { } | ||
44 | static inline void shm_exit_ns(struct ipc_namespace *ns) { } | ||
45 | #endif | ||
30 | 46 | ||
31 | /* | 47 | /* |
32 | * Structure that holds the parameters needed by the ipc operations | 48 | * Structure that holds the parameters needed by the ipc operations |