]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/commitdiff
[MIPS] Alchemy: replace ffs() with __ffs()
authorSergei Shtylyov <sshtylyov@ru.mvista.com>
Wed, 5 Dec 2007 16:08:24 +0000 (19:08 +0300)
committerRalf Baechle <ralf@linux-mips.org>
Thu, 6 Dec 2007 17:15:58 +0000 (17:15 +0000)
Fix havoc wrought by commit 56f621c7f6f735311eed3f36858b402013023c18 --
au_ffs() and ffs() are equivalent, that patch should have just replaced one
with another.  Now replace ffs() with __ffs() which returns an unbiased bit
number.

Signed-off-by: Sergei Shtylyov <sshtylyov@ru.mvista.com>
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
arch/mips/au1000/common/dbdma.c
arch/mips/au1000/common/irq.c
arch/mips/au1000/pb1200/irqmap.c

index 9d6ad43fded6865ad7911bf73896e9423b9d3cb6..edf91f41a78671c3108563b13e5b8cdaadbc11cf 100644 (file)
@@ -859,7 +859,7 @@ dbdma_interrupt(int irq, void *dev_id)
 
        intstat = dbdma_gptr->ddma_intstat;
        au_sync();
-       chan_index = ffs(intstat);
+       chan_index = __ffs(intstat);
 
        ctp = chan_tab_ptr[chan_index];
        cp = ctp->chan_ptr;
index ddfb7f0a17a627f52679b8b13a44e934bb6dc1f8..b7f1bbf6d5aad243f73bd8bf6898cd8995172bcc 100644 (file)
@@ -462,7 +462,7 @@ static void intc0_req0_irqdispatch(void)
                return;
        }
 #endif
-       bit = ffs(intc0_req0);
+       bit = __ffs(intc0_req0);
        intc0_req0 &= ~(1 << bit);
        do_IRQ(MIPS_CPU_IRQ_BASE + bit);
 }
@@ -478,7 +478,7 @@ static void intc0_req1_irqdispatch(void)
        if (!intc0_req1)
                return;
 
-       bit = ffs(intc0_req1);
+       bit = __ffs(intc0_req1);
        intc0_req1 &= ~(1 << bit);
        do_IRQ(bit);
 }
@@ -498,7 +498,7 @@ static void intc1_req0_irqdispatch(void)
        if (!intc1_req0)
                return;
 
-       bit = ffs(intc1_req0);
+       bit = __ffs(intc1_req0);
        intc1_req0 &= ~(1 << bit);
        do_IRQ(MIPS_CPU_IRQ_BASE + 32 + bit);
 }
@@ -514,7 +514,7 @@ static void intc1_req1_irqdispatch(void)
        if (!intc1_req1)
                return;
 
-       bit = ffs(intc1_req1);
+       bit = __ffs(intc1_req1);
        intc1_req1 &= ~(1 << bit);
        do_IRQ(MIPS_CPU_IRQ_BASE + 32 + bit);
 }
index c096be4ed4e785f8c2a9a625360aec1b715cefcf..8fcd0df86f93248e4e7a0fdf1eff33fd70647bae 100644 (file)
@@ -74,7 +74,7 @@ irqreturn_t pb1200_cascade_handler( int irq, void *dev_id)
        bcsr->int_status = bisr;
        for( ; bisr; bisr &= (bisr-1) )
        {
-               extirq_nr = PB1200_INT_BEGIN + ffs(bisr);
+               extirq_nr = PB1200_INT_BEGIN + __ffs(bisr);
                /* Ack and dispatch IRQ */
                do_IRQ(extirq_nr);
        }