Michal Nazarewicz wrote:
> 
Hi :-)

> On Tue, 28 Sep 2010 14:45:59 +0200, Sergei Shtylyov <sshtyl...@mvista.com>
> wrote:
> 
> > Hello.
> >
> > On 28-09-2010 5:31, Kukjin Kim wrote:
> >
> >> From: Changhwan Youn<chaos.y...@samsung.com>
> >
> >> It is reported by Junseok Jung that using clz instruction is
> >> better instead of using for-loop to find the interrupt source.
> >> This patch modifies interrupt source searching code using __fls().
> >> The __fls() is implemented using clz instruction.
> >
> >> Suggested-by: Junseok Jung<jundols.j...@samsung.com>
> >> Signed-off-by: Changhwan Youn<chaos.y...@samsung.com>
> >> Signed-off-by: Kukjin Kim<kgene....@samsung.com>
> >> ---
> >>   arch/arm/mach-s5pv310/irq-combiner.c |    6 +-----
> >>   1 files changed, 1 insertions(+), 5 deletions(-)
> >
> >> diff --git a/arch/arm/mach-s5pv310/irq-combiner.c 
> >> b/arch/arm/mach-s5pv310/irq-
> combiner.c
> >> index 0f70521..39e3647 100644
> >> --- a/arch/arm/mach-s5pv310/irq-combiner.c
> >> +++ b/arch/arm/mach-s5pv310/irq-combiner.c
> >> @@ -66,11 +66,7 @@ static void combiner_handle_cascade_irq(unsigned int
> irq, struct irq_desc *desc)
> >>    if (status == 0)
> >>            goto out;
> >>
> >> -  for (combiner_irq = 0; combiner_irq<  32; combiner_irq++) {
> >> -          if (status & 0x1)
> >> -                  break;
> >> -          status>>= 1;
> >> -  }
> >> +  combiner_irq = __fls(status);
> >
> >     But the loop finds the *first* set bit, not the last...
> 
> __ffs than?
> 
Yes, already re-submitted.

Thanks.

Best regards,
Kgene.
--
Kukjin Kim <kgene....@samsung.com>, Senior Engineer,
SW Solution Development Team, Samsung Electronics Co., Ltd.

--
To unsubscribe from this list: send the line "unsubscribe linux-samsung-soc" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to