From 3fbc96486459324e182717b03c50c90c880be6ec Mon Sep 17 00:00:00 2001 From: Sukadev Bhattiprolu Date: Mon, 2 Oct 2006 02:17:24 -0700 Subject: [PATCH] Define struct pspace Define a per-container pid space object. And create one instance of this object, init_pspace, to define the entire pid space. Subsequent patches will provide/use interfaces to create/destroy pid spaces. Its a subset/rework of Eric Biederman's patch http://lkml.org/lkml/2006/2/6/285 . Signed-off-by: Eric Biederman Signed-off-by: Sukadev Bhattiprolu Cc: Dave Hansen Cc: Serge Hallyn Cc: Cedric Le Goater Cc: Kirill Korotaev Cc: Andrey Savochkin Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- include/linux/pspace.h | 7 +++++++ include/linux/sched.h | 1 - 2 files changed, 7 insertions(+), 1 deletion(-) (limited to 'include') diff --git a/include/linux/pspace.h b/include/linux/pspace.h index a8a064b0ad18..91d48b8b2d99 100644 --- a/include/linux/pspace.h +++ b/include/linux/pspace.h @@ -13,4 +13,11 @@ struct pidmap { #define PIDMAP_ENTRIES ((PID_MAX_LIMIT + 8*PAGE_SIZE - 1)/PAGE_SIZE/8) +struct pspace { + struct pidmap pidmap[PIDMAP_ENTRIES]; + int last_pid; +}; + +extern struct pspace init_pspace; + #endif /* _LINUX_PSPACE_H */ diff --git a/include/linux/sched.h b/include/linux/sched.h index dd6c2164e4a4..3b7c99265ace 100644 --- a/include/linux/sched.h +++ b/include/linux/sched.h @@ -118,7 +118,6 @@ extern unsigned long avenrun[]; /* Load averages */ extern unsigned long total_forks; extern int nr_threads; -extern int last_pid; DECLARE_PER_CPU(unsigned long, process_counts); extern int nr_processes(void); extern unsigned long nr_running(void); -- cgit v1.2.1