pinctrl: qcom: Don't clear status bit on irq_unmask
authorBjorn Andersson <bjorn.andersson@linaro.org>
Tue, 14 Mar 2017 15:23:26 +0000 (08:23 -0700)
committerLinus Walleij <linus.walleij@linaro.org>
Thu, 23 Mar 2017 09:10:39 +0000 (10:10 +0100)
Clearing the status bit on irq_unmask will discard any pending interrupt
that did arrive after the irq_ack, i.e. while the IRQ handler function
was executing.

Fixes: f365be092572 ("pinctrl: Add Qualcomm TLMM driver")
Cc: stable@vger.kernel.org
Cc: Stephen Boyd <sboyd@codeaurora.org>
Reported-by: Timur Tabi <timur@codeaurora.org>
Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
drivers/pinctrl/qcom/pinctrl-msm.c

index c978be5eb9ebe37a4e9df59c76791b79b47b6cfc..273badd925611aa86e19e3a4aebc6691cf812fcb 100644 (file)
@@ -609,10 +609,6 @@ static void msm_gpio_irq_unmask(struct irq_data *d)
 
        raw_spin_lock_irqsave(&pctrl->lock, flags);
 
-       val = readl(pctrl->regs + g->intr_status_reg);
-       val &= ~BIT(g->intr_status_bit);
-       writel(val, pctrl->regs + g->intr_status_reg);
-
        val = readl(pctrl->regs + g->intr_cfg_reg);
        val |= BIT(g->intr_enable_bit);
        writel(val, pctrl->regs + g->intr_cfg_reg);