diff options
Diffstat (limited to 'include/linux/pid_namespace.h')
-rw-r--r-- | include/linux/pid_namespace.h | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/include/linux/pid_namespace.h b/include/linux/pid_namespace.h new file mode 100644 index 000000000000..54d79095e295 --- /dev/null +++ b/include/linux/pid_namespace.h | |||
@@ -0,0 +1,23 @@ | |||
1 | #ifndef _LINUX_PID_NS_H | ||
2 | #define _LINUX_PID_NS_H | ||
3 | |||
4 | #include <linux/sched.h> | ||
5 | #include <linux/mm.h> | ||
6 | #include <linux/threads.h> | ||
7 | #include <linux/pid.h> | ||
8 | |||
9 | struct pidmap { | ||
10 | atomic_t nr_free; | ||
11 | void *page; | ||
12 | }; | ||
13 | |||
14 | #define PIDMAP_ENTRIES ((PID_MAX_LIMIT + 8*PAGE_SIZE - 1)/PAGE_SIZE/8) | ||
15 | |||
16 | struct pid_namespace { | ||
17 | struct pidmap pidmap[PIDMAP_ENTRIES]; | ||
18 | int last_pid; | ||
19 | }; | ||
20 | |||
21 | extern struct pid_namespace init_pid_ns; | ||
22 | |||
23 | #endif /* _LINUX_PID_NS_H */ | ||