48 lines
1.5 KiB
Diff
48 lines
1.5 KiB
Diff
From 41d9204c142d8245f898ca877b4e4044d5db2426 Mon Sep 17 00:00:00 2001
|
|
From: Romuald JEANNE <romuald.jeanne@st.com>
|
|
Date: Fri, 21 Dec 2018 16:58:12 +0100
|
|
Subject: [PATCH 47/52] ARM: stm32mp1-r0-rc4: PINCTRL PWM RESET RTC
|
|
|
|
---
|
|
drivers/pinctrl/pinctrl-stmfx.c | 10 ++++++----
|
|
1 file changed, 6 insertions(+), 4 deletions(-)
|
|
|
|
diff --git a/drivers/pinctrl/pinctrl-stmfx.c b/drivers/pinctrl/pinctrl-stmfx.c
|
|
index 15d5757..b68fece 100644
|
|
--- a/drivers/pinctrl/pinctrl-stmfx.c
|
|
+++ b/drivers/pinctrl/pinctrl-stmfx.c
|
|
@@ -542,6 +542,7 @@ static irqreturn_t stmfx_pinctrl_irq_thread_fn(int irq, void *dev_id)
|
|
struct stmfx_pinctrl *pctl = (struct stmfx_pinctrl *)dev_id;
|
|
struct gpio_chip *gc = &pctl->gpio_chip;
|
|
u8 pending[NR_GPIO_REGS];
|
|
+ u8 src[NR_GPIO_REGS] = {0, 0, 0};
|
|
unsigned long n, status;
|
|
int ret;
|
|
|
|
@@ -550,10 +551,8 @@ static irqreturn_t stmfx_pinctrl_irq_thread_fn(int irq, void *dev_id)
|
|
if (ret)
|
|
return IRQ_NONE;
|
|
|
|
- ret = regmap_bulk_write(pctl->stmfx->map, STMFX_REG_IRQ_GPI_ACK,
|
|
- pending, NR_GPIO_REGS);
|
|
- if (ret)
|
|
- return IRQ_NONE;
|
|
+ regmap_bulk_write(pctl->stmfx->map, STMFX_REG_IRQ_GPI_SRC,
|
|
+ src, NR_GPIO_REGS);
|
|
|
|
status = *(unsigned long *)pending;
|
|
for_each_set_bit(n, &status, gc->ngpio) {
|
|
@@ -561,6 +560,9 @@ static irqreturn_t stmfx_pinctrl_irq_thread_fn(int irq, void *dev_id)
|
|
stmfx_pinctrl_irq_toggle_trigger(pctl, n);
|
|
}
|
|
|
|
+ regmap_bulk_write(pctl->stmfx->map, STMFX_REG_IRQ_GPI_SRC,
|
|
+ pctl->irq_gpi_src, NR_GPIO_REGS);
|
|
+
|
|
return IRQ_HANDLED;
|
|
}
|
|
|
|
--
|
|
2.7.4
|
|
|