[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20220223023157.3478540-4-peng.fan@oss.nxp.com>
Date: Wed, 23 Feb 2022 10:31:55 +0800
From: "Peng Fan (OSS)" <peng.fan@....nxp.com>
To: jassisinghbrar@...il.com, robh+dt@...nel.org, shawnguo@...nel.org
Cc: s.hauer@...gutronix.de, kernel@...gutronix.de, festevam@...il.com,
linux-imx@....com, linux-kernel@...r.kernel.org,
devicetree@...r.kernel.org, linux-arm-kernel@...ts.infradead.org,
krzysztof.kozlowski@...onical.com, daniel.baluta@....com,
Peng Fan <peng.fan@....com>
Subject: [PATCH V4 3/5] mailbox: imx: extend irq to an array
From: Peng Fan <peng.fan@....com>
To i.MX93 S401 MU, there are two interrupts: rx full and tx empty.
So extend irq to an array to prepare i.MX93 S401 MU support.
Signed-off-by: Peng Fan <peng.fan@....com>
---
drivers/mailbox/imx-mailbox.c | 14 +++++++-------
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/drivers/mailbox/imx-mailbox.c b/drivers/mailbox/imx-mailbox.c
index cd011ca5707e..03699843a6fd 100644
--- a/drivers/mailbox/imx-mailbox.c
+++ b/drivers/mailbox/imx-mailbox.c
@@ -80,7 +80,7 @@ struct imx_mu_priv {
struct imx_mu_con_priv con_priv[IMX_MU_CHANS];
const struct imx_mu_dcfg *dcfg;
struct clk *clk;
- int irq;
+ int irq[IMX_MU_CHANS];
bool suspend;
u32 xcr[4];
@@ -551,11 +551,11 @@ static int imx_mu_startup(struct mbox_chan *chan)
if (!priv->dev->pm_domain)
irq_flag |= IRQF_NO_SUSPEND;
- ret = request_irq(priv->irq, imx_mu_isr, irq_flag,
+ ret = request_irq(priv->irq[0], imx_mu_isr, irq_flag,
cp->irq_desc, chan);
if (ret) {
dev_err(priv->dev,
- "Unable to acquire IRQ %d\n", priv->irq);
+ "Unable to acquire IRQ %d\n", priv->irq[0]);
return ret;
}
@@ -598,7 +598,7 @@ static void imx_mu_shutdown(struct mbox_chan *chan)
break;
}
- free_irq(priv->irq, chan);
+ free_irq(priv->irq[0], chan);
pm_runtime_put_sync(priv->dev);
}
@@ -762,9 +762,9 @@ static int imx_mu_probe(struct platform_device *pdev)
if (IS_ERR(priv->base))
return PTR_ERR(priv->base);
- priv->irq = platform_get_irq(pdev, 0);
- if (priv->irq < 0)
- return priv->irq;
+ priv->irq[0] = platform_get_irq(pdev, 0);
+ if (priv->irq[0] < 0)
+ return priv->irq[0];
dcfg = of_device_get_match_data(dev);
if (!dcfg)
--
2.25.1
Powered by blists - more mailing lists