Skip to contentSkip to conversation

A smal chg proposal about: [PATCH] [PARISC] Allow nested interrupts

parisc-linux Joel Soete 1 participant 1 message Sep 17, 2006

lore
Share & tools
lore

Joel Soete

author
#0 lore raw

Hello James,

Sorry to have read it so lately but I just figure out this:
- we can read in:
include/linux/bitops.h
--- snip ---
static inline unsigned fls_long(unsigned long l)

{
        if (sizeof(l) == 4)
                return fls(l);
        return fls64(l);
}

--- snip ---

- otoh in your patch you wrote:
+static inline int eirr_to_irq(unsigned long eirr) +{
+#ifdef CONFIG_64BIT
+ int bit = fls64(eirr);
+#else
+ int bit = fls(eirr);
+#endif
+ return (BITS_PER_LONG - bit) + TIMER_IRQ;
+}
+

so may be could it be simply writen:

	int bit = fls_long(eirr);

Hth,
Joel

PS: I still have somewhere an optimized version for this stuff I will try to find it back ;-)
_______________________________________________
parisc-linux mailing list
[email protected]
http://lists.parisc-linux.org/mailman/listinfo/parisc-linux