Messages in this thread | | | Date | Wed, 2 May 2012 00:18:45 +0200 | Subject | Re: [PATCH 5/6] mfd/ab8500: support of hierachical interrupt | From | Linus Walleij <> |
| |
On Tue, May 1, 2012 at 1:31 PM, Samuel Ortiz <sameo@linux.intel.com> wrote:
> On Tue, Apr 17, 2012 at 09:30:49AM +0200, Linus Walleij wrote: >> +static irqreturn_t ab8500_hierarchical_irq(int irq, void *dev) >> +{
>> + /* Hierarchical interrupt version */ >> + for (i = 0; i < AB8500_IT_LATCHHIER_NUM; i++) { >> + do { >> + int latch_bit = __ffs(hier_val); >> + do { >> + int int_bit = __ffs(latch_val); >> + } while (latch_val); >> + } while (hier_val); >> + } >> + return IRQ_HANDLED; >> +} > > With 4 nested loops, this one is getting difficult to read. Have you > considered splitting the loops into separate routines ?
I get the point :-D
Michel do you think this can be done?
Yours, Linus Walleij -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
| |