[sparc32] [2/13] sparc32 init_idle()

William Lee Irwin III
2004-08-05T04:40:25Z

On Wed, Aug 04, 2004 at 09:38:17PM -0700, William Lee Irwin III wrote:
> viro needs to do sparse work on sparc32, so this series of patches
> fixes up the compile for him.

An analysis of the code determined that AP initialization called
init_idle() no less than three times, 2 out of the three with incorrect
numbers of arguments. This patch removes the superfluous calls.

Index: mm2-2.6.8-rc2/arch/sparc/kernel/sun4m_smp.c
===================================================================
--- mm2-2.6.8-rc2.orig/arch/sparc/kernel/sun4m_smp.c
+++ mm2-2.6.8-rc2/arch/sparc/kernel/sun4m_smp.c
@@ -95,8 +95,6 @@
* the SMP initialization the master will be just allowed
* to call the scheduler code.
*/
- init_idle();
-
/* Allow master to continue. */
swap((unsigned long *)&cpu_callin_map[cpuid], 1);

Index: mm2-2.6.8-rc2/arch/sparc/kernel/sun4d_smp.c
===================================================================
--- mm2-2.6.8-rc2.orig/arch/sparc/kernel/sun4d_smp.c
+++ mm2-2.6.8-rc2/arch/sparc/kernel/sun4d_smp.c
@@ -100,8 +100,6 @@
* the SMP initialization the master will be just allowed
* to call the scheduler code.
*/
- init_idle();
-
/* Get our local ticker going. */
smp_setup_percpu_timer();

Index: mm2-2.6.8-rc2/arch/sparc/kernel/trampoline.S
===================================================================
--- mm2-2.6.8-rc2.orig/arch/sparc/kernel/trampoline.S
+++ mm2-2.6.8-rc2/arch/sparc/kernel/trampoline.S
@@ -88,8 +88,6 @@
.align 4

smp_do_cpu_idle:
- call init_idle
- nop
call cpu_idle
mov 0, %o0