linux/arch/arm/mm
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
..
abort-ev4.S Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
abort-ev4t.S Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
abort-ev5t.S Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
abort-ev5tj.S Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
abort-ev6.S [ARM] CONFIG_CPU_MPCORE -> CONFIG_CPU_32v6K 2006-02-22 21:13:28 +00:00
abort-ev7.S [ARM] armv7: add support for ARMv7 cores. 2007-05-08 22:55:53 +01:00
abort-lv4t.S [ARM] nommu: abort handler fixup for !CPU_CP15_MMU cores. 2006-09-28 20:15:46 +01:00
abort-macro.S Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
abort-nommu.S [ARM] nommu: abort handler fixup for !CPU_CP15_MMU cores. 2006-09-28 20:15:46 +01:00
alignment.c parse errors in ifdefs 2007-06-01 08:18:28 -07:00
cache-l2x0.c [ARM] 4568/1: fix l2x0 cache invalidate handling of unaligned addresses 2007-09-17 14:56:39 +01:00
cache-v3.S Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
cache-v4.S [ARM] nommu: manage the CP15 things 2006-09-27 17:34:30 +01:00
cache-v4wb.S Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
cache-v4wt.S Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
cache-v6.S [ARM] 3356/1: Workaround for the ARM1136 I-cache invalidation problem 2006-03-10 22:26:47 +00:00
cache-v7.S [ARM] armv7: add support for ARMv7 cores. 2007-05-08 22:55:53 +01:00
consistent.c [ARM] Rename consistent_sync() as dma_cache_maint() 2007-10-12 23:43:45 +01:00
context.c Merge branches 'armv7', 'at91', 'misc' and 'omap' into devel 2007-05-09 10:41:28 +01:00
copypage-v3.S [ARM] Remove LOADREGS macro 2006-06-25 11:23:45 +01:00
copypage-v4mc.c [ARM] 4078/1: Fix ARM copypage cache coherency problems 2006-12-30 17:05:08 +00:00
copypage-v4wb.S kbuild: arm - use generic asm-offsets.h support 2005-09-09 21:08:59 +02:00
copypage-v4wt.S kbuild: arm - use generic asm-offsets.h support 2005-09-09 21:08:59 +02:00
copypage-v6.c [ARM] 4078/1: Fix ARM copypage cache coherency problems 2006-12-30 17:05:08 +00:00
copypage-xsc3.S [ARM] 3377/2: add support for intel xsc3 core 2006-03-28 21:00:40 +01:00
copypage-xscale.c [ARM] 4078/1: Fix ARM copypage cache coherency problems 2006-12-30 17:05:08 +00:00
discontig.c [ARM] Cleanup ARM includes 2006-01-03 17:39:34 +00:00
extable.c Linux-2.6.12-rc2 2005-04-16 15:20:36 -07:00
fault-armv.c [ARM] 4191/1: Remove redundant __flush_dcache_page() function prototype 2007-02-16 12:57:55 +00:00
fault.c pid namespaces: define is_global_init() and is_container_init() 2007-10-19 11:53:37 -07:00
fault.h [ARM] do_bad_area() always takes current and current->active_mm 2006-09-27 16:13:48 +01:00
flush.c [ARM] Resolve fuse and direct-IO failures due to missing cache flushes 2007-01-08 19:49:58 +00:00
init.c [ARM] Remove needless linux/ptrace.h includes 2007-04-21 20:34:47 +01:00
iomap.c [ARM] nommu: add stubs for ioremap and friends 2006-06-28 17:59:48 +01:00
ioremap.c [ARM] Fix bounding error in ioremap_pfn() 2007-07-12 11:13:33 +01:00
Kconfig [ARM] pxa: PXA3xx base support 2007-10-15 18:53:43 +01:00
Makefile [ARM] 4394/1: ARMv7: Add the TLB range operations 2007-05-30 14:32:07 +01:00
mm.h [ARM] mm 6: allow mem_types table to specify extended pte attributes 2007-04-21 20:36:02 +01:00
mmap.c Detach sched.h from mm.h 2007-05-21 09:18:19 -07:00
mmu.c [ARM] 4497/1: Only allow safe cache configurations on ARMv6 and later 2007-07-20 21:42:35 +01:00
nommu.c [ARM] mm 10: allow memory type to be specified with ioremap 2007-05-05 20:59:27 +01:00
pgd.c [ARM] Unuse another Linux PTE bit 2006-12-13 14:34:43 +00:00
proc-arm6_7.S [ARM] Unuse another Linux PTE bit 2006-12-13 14:34:43 +00:00
proc-arm7tdmi.S [ARM] Include asm/elf.h instead of asm/procinfo.h 2006-11-30 12:24:46 +00:00
proc-arm9tdmi.S [ARM] Include asm/elf.h instead of asm/procinfo.h 2006-11-30 12:24:46 +00:00
proc-arm720.S [ARM] Unuse another Linux PTE bit 2006-12-13 14:34:43 +00:00
proc-arm740.S [ARM] Include asm/elf.h instead of asm/procinfo.h 2006-11-30 12:24:46 +00:00
proc-arm920.S [ARM] Unuse another Linux PTE bit 2006-12-13 14:34:43 +00:00
proc-arm922.S [ARM] Unuse another Linux PTE bit 2006-12-13 14:34:43 +00:00
proc-arm925.S [ARM] Unuse another Linux PTE bit 2006-12-13 14:34:43 +00:00
proc-arm926.S [ARM] Unuse another Linux PTE bit 2006-12-13 14:34:43 +00:00
proc-arm940.S [ARM] Include asm/elf.h instead of asm/procinfo.h 2006-11-30 12:24:46 +00:00
proc-arm946.S [ARM] Include asm/elf.h instead of asm/procinfo.h 2006-11-30 12:24:46 +00:00
proc-arm1020.S [ARM] Unuse another Linux PTE bit 2006-12-13 14:34:43 +00:00
proc-arm1020e.S [ARM] Unuse another Linux PTE bit 2006-12-13 14:34:43 +00:00
proc-arm1022.S [ARM] Unuse another Linux PTE bit 2006-12-13 14:34:43 +00:00
proc-arm1026.S [ARM] Unuse another Linux PTE bit 2006-12-13 14:34:43 +00:00
proc-macros.S [ARM] armv7: add support for ARMv7 cores. 2007-05-08 22:55:53 +01:00
proc-sa110.S [ARM] Unuse another Linux PTE bit 2006-12-13 14:34:43 +00:00
proc-sa1100.S [ARM] Unuse another Linux PTE bit 2006-12-13 14:34:43 +00:00
proc-syms.c [ARM] 4502/1: nommu: Do not export the copy/clear user page functions 2007-07-20 21:29:51 +01:00
proc-v6.S Merge Realview GIC code 2007-02-15 15:07:40 +00:00
proc-v7.S [ARM] 4503/1: nommu: Add noMMU support for ARMv7 2007-07-20 21:42:13 +01:00
proc-xsc3.S [ARM] 4123/1: xsc3: general cleanup 2007-02-08 14:48:44 +00:00
proc-xscale.S [ARM] 4311/1: ixp4xx: add KIXRP435 platform 2007-04-21 20:51:55 +01:00
tlb-v3.S kbuild: arm - use generic asm-offsets.h support 2005-09-09 21:08:59 +02:00
tlb-v4.S kbuild: arm - use generic asm-offsets.h support 2005-09-09 21:08:59 +02:00
tlb-v4wb.S kbuild: arm - use generic asm-offsets.h support 2005-09-09 21:08:59 +02:00
tlb-v4wbi.S kbuild: arm - use generic asm-offsets.h support 2005-09-09 21:08:59 +02:00
tlb-v6.S [ARM] 4129/1: Add barriers after the TLB operations 2007-02-08 14:49:27 +00:00
tlb-v7.S [ARM] 4394/1: ARMv7: Add the TLB range operations 2007-05-30 14:32:07 +01:00