]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/commitdiff
sh: smp: shove a cpu_relax() in the plat_start_cpu() busy loop.
authorPaul Mundt <lethal@linux-sh.org>
Wed, 6 Aug 2008 09:39:32 +0000 (18:39 +0900)
committerPaul Mundt <lethal@linux-sh.org>
Mon, 8 Sep 2008 01:35:03 +0000 (10:35 +0900)
Without this, certain versions of GCC will happily optimize the entire
loop out.

Signed-off-by: Paul Mundt <lethal@linux-sh.org>
arch/sh/kernel/cpu/sh4a/smp-shx3.c

index edb4da037e0cdbfd7e94b1c9d60e85e21a92c870..b8869aa20decb6f281407ab7aef1c136f486757c 100644 (file)
@@ -82,7 +82,7 @@ void plat_start_cpu(unsigned int cpu, unsigned long entry_point)
                ctrl_outl(STBCR_MSTP, STBCR_REG(cpu));
 
        while (!(ctrl_inl(STBCR_REG(cpu)) & STBCR_MSTP))
-               ;
+               cpu_relax();
 
        /* Start up secondary processor by sending a reset */
        ctrl_outl(STBCR_AP_VAL, STBCR_REG(cpu));