summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTanmay Shah <tanmay.shah@amd.com>2023-03-10 17:24:05 -0800
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2023-05-11 23:11:34 +0900
commit29b5dc7aa6a301706005c8169fb06e4269001e92 (patch)
tree1f1304e9163ae0b89df92de444a7b909c99d34b0
parentf56303abe58dd9d02188a6d83c4e4f1c72a51894 (diff)
downloadlinux-29b5dc7aa6a301706005c8169fb06e4269001e92.tar.gz
linux-29b5dc7aa6a301706005c8169fb06e4269001e92.tar.bz2
linux-29b5dc7aa6a301706005c8169fb06e4269001e92.zip
mailbox: zynqmp: Fix IPI isr handling
commit 74ad37a30ffee3643bc34f9ca7225b20a66abaaf upstream. Multiple IPI channels are mapped to same interrupt handler. Current isr implementation handles only one channel per isr. Fix this behavior by checking isr status bit of all child mailbox nodes. Fixes: 4981b82ba2ff ("mailbox: ZynqMP IPI mailbox controller") Signed-off-by: Tanmay Shah <tanmay.shah@amd.com> Acked-by: Michal Simek <michal.simek@amd.com> Cc: stable@vger.kernel.org Link: https://lore.kernel.org/r/20230311012407.1292118-3-tanmay.shah@amd.com Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r--drivers/mailbox/zynqmp-ipi-mailbox.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/mailbox/zynqmp-ipi-mailbox.c b/drivers/mailbox/zynqmp-ipi-mailbox.c
index 12e004ff1a14..e02a4a18e8c2 100644
--- a/drivers/mailbox/zynqmp-ipi-mailbox.c
+++ b/drivers/mailbox/zynqmp-ipi-mailbox.c
@@ -152,7 +152,7 @@ static irqreturn_t zynqmp_ipi_interrupt(int irq, void *data)
struct zynqmp_ipi_message *msg;
u64 arg0, arg3;
struct arm_smccc_res res;
- int ret, i;
+ int ret, i, status = IRQ_NONE;
(void)irq;
arg0 = SMC_IPI_MAILBOX_STATUS_ENQUIRY;
@@ -170,11 +170,11 @@ static irqreturn_t zynqmp_ipi_interrupt(int irq, void *data)
memcpy_fromio(msg->data, mchan->req_buf,
msg->len);
mbox_chan_received_data(chan, (void *)msg);
- return IRQ_HANDLED;
+ status = IRQ_HANDLED;
}
}
}
- return IRQ_NONE;
+ return status;
}
/**