[PATCH 3/9] ARM: smp: avoid using bitmasks and locks for IPIs, use hardware instead

Russell King - ARM Linux linux at arm.linux.org.uk
Wed Nov 17 12:19:20 EST 2010


On Wed, Nov 17, 2010 at 05:06:39PM +0000, Catalin Marinas wrote:
> On Mon, 2010-11-15 at 17:58 +0000, Russell King - ARM Linux wrote:
> > Avoid using bitmasks and locks in the percpu area for IPIs, and instead
> > use individual software generated interrupts to identify the reason for
> > the IPI.  This avoids the problems of having spinlocks in the percpu
> > area.
> > 
> > Signed-off-by: Russell King <rmk+kernel at arm.linux.org.uk>
> > ---
> >  arch/arm/kernel/smp.c |   87 ++++++++++++++----------------------------------
> >  1 files changed, 26 insertions(+), 61 deletions(-)
> > 
> > diff --git a/arch/arm/kernel/smp.c b/arch/arm/kernel/smp.c
> > index 7a236db..78d55c6 100644
> > --- a/arch/arm/kernel/smp.c
> > +++ b/arch/arm/kernel/smp.c
> [...]
> >  enum ipi_msg_type {
> > -       IPI_TIMER,
> > +       IPI_TIMER = 2,
> >         IPI_RESCHEDULE,
> >         IPI_CALL_FUNC,
> >         IPI_CALL_FUNC_SINGLE,
> 
> Maybe a comment here on why this starts at 2. People may wonder in the
> future.

I would like to get rid of the 'starts at 2' but we can only do this once
we're sure that the use of SGI1 to wake up the CPUs is not something that
is a hard requirement for boot loaders.

I've not yet tested whether Realview and Versatile Express are fine with
a different SGI number.



More information about the linux-arm-kernel mailing list