Re: [PATCH] sparc: Use generic idle loop

2013-04-08 Thread David Miller
From: Sam Ravnborg Date: Mon, 8 Apr 2013 19:10:35 +0200 > I think not. > local_irq_disable writes 0 to the PIL register, > whereas the above code set the IE (Interrupt enable) bit to 0. > > So the implementations differs - and I think there is a good > reason for being so. > > But this is the

Re: [PATCH] sparc: Use generic idle loop

2013-04-08 Thread Sam Ravnborg
> > @@ -52,17 +52,12 @@ > > > > #include "kstack.h" > > > > -static void sparc64_yield(int cpu) > > +/* Idle loop support on sparc64. */ > > +void arch_cpu_idle(void) > > { > > if (tlb_type != hypervisor) { > > touch_nmi_watchdog(); > > - return; > > - } > > - > > -

Re: [PATCH] sparc: Use generic idle loop

2013-04-08 Thread Srivatsa S. Bhat
Hi Sam, On 04/01/2013 02:36 PM, Sam Ravnborg wrote: > Hi Srivatsa, > > thanks for the feedback! > > @davem - I need you to look at this again. I am not sure about the changes > I do in sparc64_yield(). > >>> +/* the idle loop on a Sparc... ;) */ >>> +void arch_cpu_idle(void) >>> { >>> + if

Re: [PATCH] sparc: Use generic idle loop

2013-04-08 Thread Srivatsa S. Bhat
Hi Sam, On 04/01/2013 02:36 PM, Sam Ravnborg wrote: Hi Srivatsa, thanks for the feedback! @davem - I need you to look at this again. I am not sure about the changes I do in sparc64_yield(). +/* the idle loop on a Sparc... ;) */ +void arch_cpu_idle(void) { + if (sparc_idle) +

Re: [PATCH] sparc: Use generic idle loop

2013-04-08 Thread Sam Ravnborg
@@ -52,17 +52,12 @@ #include kstack.h -static void sparc64_yield(int cpu) +/* Idle loop support on sparc64. */ +void arch_cpu_idle(void) { if (tlb_type != hypervisor) { touch_nmi_watchdog(); - return; - } - -

Re: [PATCH] sparc: Use generic idle loop

2013-04-08 Thread David Miller
From: Sam Ravnborg s...@ravnborg.org Date: Mon, 8 Apr 2013 19:10:35 +0200 I think not. local_irq_disable writes 0 to the PIL register, whereas the above code set the IE (Interrupt enable) bit to 0. So the implementations differs - and I think there is a good reason for being so. But

Re: [PATCH] sparc: Use generic idle loop

2013-04-01 Thread Sam Ravnborg
Hi Srivatsa, thanks for the feedback! @davem - I need you to look at this again. I am not sure about the changes I do in sparc64_yield(). > > +/* the idle loop on a Sparc... ;) */ > > +void arch_cpu_idle(void) > > { > > + if (sparc_idle) > > + (*sparc_idle)(); > > + else > > +

Re: [PATCH] sparc: Use generic idle loop

2013-04-01 Thread Srivatsa S. Bhat
On 03/30/2013 01:59 AM, Sam Ravnborg wrote: > Add generic cpu_idle support > > sparc32: > - replace call to cpu_idle() with cpu_startup_entry() > - add arch_cpu_idle() > > sparc64: > - smp_callin() includes cpu_startup_entry() call so we can > skip calling cpu_idle from assembler > - add

Re: [PATCH] sparc: Use generic idle loop

2013-04-01 Thread Srivatsa S. Bhat
On 03/30/2013 01:59 AM, Sam Ravnborg wrote: Add generic cpu_idle support sparc32: - replace call to cpu_idle() with cpu_startup_entry() - add arch_cpu_idle() sparc64: - smp_callin() includes cpu_startup_entry() call so we can skip calling cpu_idle from assembler - add

Re: [PATCH] sparc: Use generic idle loop

2013-04-01 Thread Sam Ravnborg
Hi Srivatsa, thanks for the feedback! @davem - I need you to look at this again. I am not sure about the changes I do in sparc64_yield(). +/* the idle loop on a Sparc... ;) */ +void arch_cpu_idle(void) { + if (sparc_idle) + (*sparc_idle)(); + else +

Re: [PATCH] sparc: Use generic idle loop

2013-03-31 Thread David Miller
From: Sam Ravnborg Date: Fri, 29 Mar 2013 21:29:26 +0100 > Add generic cpu_idle support > > sparc32: > - replace call to cpu_idle() with cpu_startup_entry() > - add arch_cpu_idle() > > sparc64: > - smp_callin() includes cpu_startup_entry() call so we can > skip calling cpu_idle from

Re: [PATCH] sparc: Use generic idle loop

2013-03-31 Thread David Miller
From: Sam Ravnborg s...@ravnborg.org Date: Fri, 29 Mar 2013 21:29:26 +0100 Add generic cpu_idle support sparc32: - replace call to cpu_idle() with cpu_startup_entry() - add arch_cpu_idle() sparc64: - smp_callin() includes cpu_startup_entry() call so we can skip calling cpu_idle from

[PATCH] sparc: Use generic idle loop

2013-03-29 Thread Sam Ravnborg
Add generic cpu_idle support sparc32: - replace call to cpu_idle() with cpu_startup_entry() - add arch_cpu_idle() sparc64: - smp_callin() includes cpu_startup_entry() call so we can skip calling cpu_idle from assembler - add arch_cpu_idle_enter() and arch_cpu_idle_dead() Signed-off-by: Sam

[PATCH] sparc: Use generic idle loop

2013-03-29 Thread Sam Ravnborg
Add generic cpu_idle support sparc32: - replace call to cpu_idle() with cpu_startup_entry() - add arch_cpu_idle() sparc64: - smp_callin() includes cpu_startup_entry() call so we can skip calling cpu_idle from assembler - add arch_cpu_idle_enter() and arch_cpu_idle_dead() Signed-off-by: Sam