]> err.no Git - linux-2.6/commitdiff
[SPARC64]: check fork_idle() error
authorAkinobu Mita <akinobu.mita@gmail.com>
Thu, 4 Oct 2007 21:55:59 +0000 (14:55 -0700)
committerDavid S. Miller <davem@davemloft.net>
Thu, 4 Oct 2007 21:55:59 +0000 (14:55 -0700)
Check the return value of fork_idle() to catch error.

Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
arch/sparc64/kernel/smp.c

index b84c49e3697c608c826c529739328ae633a860a8..c73b7a48b0369ae970edf7d103672621eacb2e21 100644 (file)
@@ -353,6 +353,8 @@ static int __devinit smp_boot_one_cpu(unsigned int cpu)
        int timeout, ret;
 
        p = fork_idle(cpu);
+       if (IS_ERR(p))
+               return PTR_ERR(p);
        callin_flag = 0;
        cpu_new_thread = task_thread_info(p);