gpio: pca953x: remove redundant variable and check in IRQ handler
[linux-2.6-microblaze.git] / drivers / gpio / gpio-pca953x.c
index 232e3f9..9f33011 100644 (file)
@@ -743,7 +743,6 @@ static irqreturn_t pca953x_irq_handler(int irq, void *devid)
        struct pca953x_chip *chip = devid;
        u8 pending[MAX_BANK];
        u8 level;
-       unsigned nhandled = 0;
        int i;
 
        if (!pca953x_irq_pending(chip, pending))
@@ -755,11 +754,10 @@ static irqreturn_t pca953x_irq_handler(int irq, void *devid)
                        handle_nested_irq(irq_find_mapping(chip->gpio_chip.irq.domain,
                                                        level + (BANK_SZ * i)));
                        pending[i] &= ~(1 << level);
-                       nhandled++;
                }
        }
 
-       return (nhandled > 0) ? IRQ_HANDLED : IRQ_NONE;
+       return IRQ_HANDLED;
 }
 
 static int pca953x_irq_setup(struct pca953x_chip *chip,