The patch titled Subject: gpio: pca953x: remove redundant variable and check in IRQ handler has been added to the -mm tree. Its filename is gpio-pca953x-remove-redundant-variable-and-check-in-irq-handler.patch This patch should soon appear at http://ozlabs.org/~akpm/mmots/broken-out/gpio-pca953x-remove-redundant-variable-and-check-in-irq-handler.patch and later at http://ozlabs.org/~akpm/mmotm/broken-out/gpio-pca953x-remove-redundant-variable-and-check-in-irq-handler.patch Before you just go and hit "reply", please: a) Consider who else should be cc'ed b) Prefer to cc a suitable mailing list as well c) Ideally: find the original patch on the mailing list and do a reply-to-all to that, adding suitable additional cc's *** Remember to use Documentation/process/submit-checklist.rst when testing your code *** The -mm tree is included into linux-next and is updated there every 3-4 working days ------------------------------------------------------ From: Andy Shevchenko <andriy.shevchenko@xxxxxxxxxxxxxxx> Subject: gpio: pca953x: remove redundant variable and check in IRQ handler We always will have at least one iteration of the loop due to pending being guaranteed to be non-zero. That is, we may remove extra variable and check in the IRQ handler. Link: http://lkml.kernel.org/r/20191022172922.61232-9-andriy.shevchenko@xxxxxxxxxxxxxxx Signed-off-by: Andy Shevchenko <andriy.shevchenko@xxxxxxxxxxxxxxx> Cc: Bartosz Golaszewski <bgolaszewski@xxxxxxxxxxxx> Cc: Geert Uytterhoeven <geert@xxxxxxxxxxxxxx> Cc: Linus Walleij <linus.walleij@xxxxxxxxxx> Cc: Marek Vasut <marek.vasut+renesas@xxxxxxxxx> Cc: Rasmus Villemoes <linux@xxxxxxxxxxxxxxxxxx> Cc: Thomas Petazzoni <thomas.petazzoni@xxxxxxxxxxx> Cc: William Breathitt Gray <vilhelm.gray@xxxxxxxxx> Cc: Yury Norov <yury.norov@xxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- drivers/gpio/gpio-pca953x.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) --- a/drivers/gpio/gpio-pca953x.c~gpio-pca953x-remove-redundant-variable-and-check-in-irq-handler +++ a/drivers/gpio/gpio-pca953x.c @@ -740,7 +740,6 @@ static irqreturn_t pca953x_irq_handler(i struct pca953x_chip *chip = devid; u8 pending[MAX_BANK]; u8 level; - unsigned nhandled = 0; int i; if (!pca953x_irq_pending(chip, pending)) @@ -752,11 +751,10 @@ static irqreturn_t pca953x_irq_handler(i 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, _ Patches currently in -mm which might be from andriy.shevchenko@xxxxxxxxxxxxxxx are lib-test_bitmap-force-argument-of-bitmap_parselist_user-to-proper-address-space.patch lib-test_bitmap-undefine-macros-after-use.patch lib-test_bitmap-name-exp_bytes-properly.patch lib-test_bitmap-rename-exp-to-exp1-to-avoid-ambiguous-name.patch lib-test_bitmap-move-exp1-and-exp2-upper-for-others-to-use.patch lib-test_bitmap-fix-comment-about-this-file.patch bitmap-introduce-bitmap_replace-helper.patch gpio-pca953x-remove-redundant-variable-and-check-in-irq-handler.patch gpio-pca953x-use-input-from-regs-structure-in-pca953x_irq_pending.patch gpio-pca953x-convert-to-use-bitmap-api.patch gpio-pca953x-tight-up-indentation.patch