WSL2-Linux-Kernel/arch/powerpc/platforms
Serge E. Hallyn b460cbc581 pid namespaces: define is_global_init() and is_container_init()
is_init() is an ambiguous name for the pid==1 check.  Split it into
is_global_init() and is_container_init().

A cgroup init has it's tsk->pid == 1.

A global init also has it's tsk->pid == 1 and it's active pid namespace
is the init_pid_ns.  But rather than check the active pid namespace,
compare the task structure with 'init_pid_ns.child_reaper', which is
initialized during boot to the /sbin/init process and never changes.

Changelog:

	2.6.22-rc4-mm2-pidns1:
	- Use 'init_pid_ns.child_reaper' to determine if a given task is the
	  global init (/sbin/init) process. This would improve performance
	  and remove dependence on the task_pid().

	2.6.21-mm2-pidns2:

	- [Sukadev Bhattiprolu] Changed is_container_init() calls in {powerpc,
	  ppc,avr32}/traps.c for the _exception() call to is_global_init().
	  This way, we kill only the cgroup if the cgroup's init has a
	  bug rather than force a kernel panic.

[akpm@linux-foundation.org: fix comment]
[sukadev@us.ibm.com: Use is_global_init() in arch/m32r/mm/fault.c]
[bunk@stusta.de: kernel/pid.c: remove unused exports]
[sukadev@us.ibm.com: Fix capability.c to work with threaded init]
Signed-off-by: Serge E. Hallyn <serue@us.ibm.com>
Signed-off-by: Sukadev Bhattiprolu <sukadev@us.ibm.com>
Acked-by: Pavel Emelianov <xemul@openvz.org>
Cc: Eric W. Biederman <ebiederm@xmission.com>
Cc: Cedric Le Goater <clg@fr.ibm.com>
Cc: Dave Hansen <haveblue@us.ibm.com>
Cc: Herbert Poetzel <herbert@13thfloor.at>
Cc: Kirill Korotaev <dev@sw.ru>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-10-19 11:53:37 -07:00
..
8xx [POWERPC] 8xx/wrapper: Embedded Planet EP88xC support 2007-10-04 11:02:40 -05:00
40x [POWERPC] 4xx: Add AMCC Kilauea eval board support to platforms/40x 2007-10-11 15:01:50 -05:00
44x Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/paulus/powerpc 2007-10-11 21:55:47 -07:00
52xx PM: Rework struct platform_suspend_ops 2007-10-18 14:37:18 -07:00
82xx [POWERPC] mpc82xx: Add pq2fads board support. 2007-10-04 11:02:47 -05:00
83xx [POWERPC] QEIC: Implement pluggable handlers, fix MPIC cascading 2007-10-08 08:38:57 -05:00
85xx [POWERPC] 85xx: Killed <asm/mpc85xx.h> 2007-10-11 09:14:31 -05:00
86xx [POWERPC] 85xx/86xx: refactor RSTCR reset code 2007-10-08 08:38:47 -05:00
cell Slab API: remove useless ctor parameter and reorder parameters 2007-10-17 08:42:45 -07:00
celleb [POWERPC] Use 1TB segments 2007-10-12 14:05:17 +10:00
chrp [POWERPC] Platforms shouldn't mess with ROOT_DEV 2007-10-11 20:40:43 +10:00
embedded6xx [POWERPC] Use for_each_ matching routinues for pci PHBs 2007-10-08 08:38:40 -05:00
iseries [POWERPC] Fix iSeries_hpte_insert prototype 2007-10-17 22:30:08 +10:00
maple [POWERPC] maple pci_ops: Use named structure member initializers 2007-08-17 11:01:53 +10:00
pasemi pcmcia: CompactFlash driver for PA Semi Electra boards 2007-10-17 08:42:48 -07:00
powermac Merge master.kernel.org:/pub/scm/linux/kernel/git/davej/cpufreq 2007-10-12 15:42:01 -07:00
prep [POWERPC] Split several platforms into their respective Kconfig file 2007-03-22 10:07:32 -05:00
ps3 PS3: sg chaining support 2007-10-16 11:27:31 +02:00
pseries pid namespaces: define is_global_init() and is_container_init() 2007-10-19 11:53:37 -07:00
Kconfig Merge branch 'for-2.6.24' of git://git.secretlab.ca/git/linux-2.6-mpc52xx into merge 2007-10-17 22:31:13 +10:00
Kconfig.cputype [POWERPC] rheap: Changes config mechanism 2007-10-16 17:09:21 -06:00
Makefile [POWERPC] Walnut board support 2007-09-07 07:51:24 -05:00
fsl_uli1575.c [POWERPC] Fix interrupt routing and setup of ULI M1575 on FSL boards 2007-08-17 13:22:16 -05:00