Blackfin: SMP: delay enabling caches until CPU is initialized
authorsteven miao <realmz6@gmail.com>
Tue, 7 Sep 2010 10:08:36 +0000 (10:08 +0000)
committerMike Frysinger <vapier@gentoo.org>
Fri, 18 Mar 2011 08:01:02 +0000 (04:01 -0400)
Defer bfin_setup_caches(cpu) to avoid unexpected faults due to the cpu
state not yet being fully initialized.

Signed-off-by: steven miao <realmz6@gmail.com>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
arch/blackfin/mach-common/smp.c

index d3f597a92053acc36e83eb83a3e583c7cdeb922a..40e6cbc363f5fd4663d74a221400f956eeb90d06 100644 (file)
@@ -361,8 +361,6 @@ void __cpuinit secondary_start_kernel(void)
         */
        init_exception_vectors();
 
-       bfin_setup_caches(cpu);
-
        local_irq_disable();
 
        /* Attach the new idle task to the global mm. */
@@ -381,6 +379,8 @@ void __cpuinit secondary_start_kernel(void)
 
        local_irq_enable();
 
+       bfin_setup_caches(cpu);
+
        /*
         * Calibrate loops per jiffy value.
         * IRQs need to be enabled here - D-cache can be invalidated