[POWERPC] Use is_init() instead of pid==1
authorAkinobu Mita <akinobu.mita@gmail.com>
Tue, 19 Dec 2006 08:35:49 +0000 (17:35 +0900)
committerPaul Mackerras <paulus@samba.org>
Wed, 24 Jan 2007 10:13:56 +0000 (21:13 +1100)
Use is_init() rather than hard coded pid comparison.

Cc: Anton Blanchard <anton@samba.org>
Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
arch/powerpc/kernel/traps.c

index 535f50665647eb490cdc32fd48223c780d55adfd..6915b91868b823a23ef21fc3c2824063f1fe449b 100644 (file)
@@ -174,7 +174,7 @@ void _exception(int signr, struct pt_regs *regs, int code, unsigned long addr)
         * generate the same exception over and over again and we get
         * nowhere.  Better to kill it and let the kernel panic.
         */
-       if (current->pid == 1) {
+       if (is_init(current)) {
                __sighandler_t handler;
 
                spin_lock_irq(&current->sighand->siglock);