7bdebfaab6a5b18c4b9523f70efe3c7b7b1c37e6
1 #ifndef _LINUX_NSPROXY_H
2 #define _LINUX_NSPROXY_H
4 #include <linux/spinlock.h>
5 #include <linux/sched.h>
8 * A structure to contain pointers to all per-process
9 * namespaces - fs (mount), uts, network, sysvipc, etc.
11 * 'count' is the number of tasks holding a reference.
12 * The count for each namespace, then, will be the number
13 * of nsproxies pointing to it, not the number of tasks.
15 * The nsproxy is shared by tasks which share all namespaces.
16 * As soon as a single namespace is cloned or unshared, the
23 extern struct nsproxy init_nsproxy
;
25 struct nsproxy
*dup_namespaces(struct nsproxy
*orig
);
26 int copy_namespaces(int flags
, struct task_struct
*tsk
);
27 void get_task_namespaces(struct task_struct
*tsk
);
28 void free_nsproxy(struct nsproxy
*ns
);
30 static inline void put_nsproxy(struct nsproxy
*ns
)
32 if (atomic_dec_and_test(&ns
->count
)) {
37 static inline void exit_task_namespaces(struct task_struct
*p
)
39 struct nsproxy
*ns
= p
->nsproxy
;
This page took 0.034366 seconds and 5 git commands to generate.