Commit fe6a3279 authored by Alex Elder's avatar Alex Elder Committed by David S. Miller

net: ipa: get rid of some unneeded IPA interrupt code

The pending IPA interrupts are checked by ipa_isr_thread(), and
interrupts are processed only if an enabled interrupt has a
condition pending.  But ipa_interrupt_process_all() now makes the
same check, so the one in ipa_isr_thread() can just be skipped.

Also in ipa_isr_thread(), any interrupt conditions pending which are
not enabled are cleared.  Here too, ipa_interrupt_process_all() now
clears such excess interrupt conditions, so ipa_isr_thread() doesn't
have to.
Signed-off-by: default avatarAlex Elder <elder@linaro.org>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent e70e410f
...@@ -116,26 +116,11 @@ static irqreturn_t ipa_isr_thread(int irq, void *dev_id) ...@@ -116,26 +116,11 @@ static irqreturn_t ipa_isr_thread(int irq, void *dev_id)
{ {
struct ipa_interrupt *interrupt = dev_id; struct ipa_interrupt *interrupt = dev_id;
struct ipa *ipa = interrupt->ipa; struct ipa *ipa = interrupt->ipa;
u32 offset;
u32 mask;
ipa_clock_get(ipa); ipa_clock_get(ipa);
offset = ipa_reg_irq_stts_offset(ipa->version); ipa_interrupt_process_all(interrupt);
mask = ioread32(ipa->reg_virt + offset);
if (mask & interrupt->enabled) {
ipa_interrupt_process_all(interrupt);
goto out_clock_put;
}
/* Nothing in the mask was supposed to cause an interrupt */
offset = ipa_reg_irq_clr_offset(ipa->version);
iowrite32(mask, ipa->reg_virt + offset);
dev_err(&ipa->pdev->dev, "%s: unexpected interrupt, mask 0x%08x\n",
__func__, mask);
out_clock_put:
ipa_clock_put(ipa); ipa_clock_put(ipa);
return IRQ_HANDLED; return IRQ_HANDLED;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment