diff options
| author | Abhijeet Dharmapurikar <adharmap@codeaurora.org> | 2016-01-18 20:46:25 -0800 |
|---|---|---|
| committer | Rohit Vaswani <rvaswani@codeaurora.org> | 2016-03-01 12:22:47 -0800 |
| commit | d08f416687fb1cf36d2a6765d0fa5096a12f0e19 (patch) | |
| tree | 824dfa1d2852fb053ddf6823fc7f3f47614271f5 | |
| parent | e4955de860441189c8359bcd7a44331ec708a36a (diff) | |
spmi: pmic-arb: fix missing interrupts
irq_enable which is called when the device resumes. Note that the
irq_enable is called regardless of whether the interrupt was
marked enabled/disabled in the descriptor or whether it was
masked/unmaked at the controller while resuming.
The current driver unconditionally clears the interrupt in its
irq_enable callback. This is dangerous as any interrupts that
happen right before the resume could be missed.
Remove the irq_enable callback and use mask/unmask instead.
Change-Id: I58695ae0c4905a699003d35498dc36c2a947f3f0
Signed-off-by: Abhijeet Dharmapurikar <adharmap@codeaurora.org>
| -rw-r--r-- | drivers/spmi/spmi-pmic-arb.c | 12 |
1 files changed, 0 insertions, 12 deletions
diff --git a/drivers/spmi/spmi-pmic-arb.c b/drivers/spmi/spmi-pmic-arb.c index d0ddc59019b3..f5b22175ee49 100644 --- a/drivers/spmi/spmi-pmic-arb.c +++ b/drivers/spmi/spmi-pmic-arb.c @@ -638,17 +638,6 @@ static void qpnpint_irq_unmask(struct irq_data *d) qpnpint_spmi_write(d, QPNPINT_REG_EN_SET, &data, 1); } -static void qpnpint_irq_enable(struct irq_data *d) -{ - u8 irq = d->hwirq >> 8; - u8 data; - - qpnpint_irq_unmask(d); - - data = BIT(irq); - qpnpint_spmi_write(d, QPNPINT_REG_LATCHED_CLR, &data, 1); -} - static int qpnpint_irq_set_type(struct irq_data *d, unsigned int flow_type) { struct spmi_pmic_arb_qpnpint_type type; @@ -697,7 +686,6 @@ static int qpnpint_get_irqchip_state(struct irq_data *d, static struct irq_chip pmic_arb_irqchip = { .name = "pmic_arb", - .irq_enable = qpnpint_irq_enable, .irq_ack = qpnpint_irq_ack, .irq_mask = qpnpint_irq_mask, .irq_unmask = qpnpint_irq_unmask, |
