[PATCH v2 5/9] mailbox: imx: Start splitting the IRQ handler in primary and threaded handler
Sebastian Andrzej Siewior
bigeasy at linutronix.de
Mon Jun 8 02:37:58 PDT 2026
On 2026-06-08 13:32:49 [+0800], Peng Fan wrote:
> > drivers/mailbox/imx-mailbox.c | 33 ++++++++++++++++++++++++++++++---
> > 1 file changed, 30 insertions(+), 3 deletions(-)
> >
> >diff --git a/drivers/mailbox/imx-mailbox.c b/drivers/mailbox/imx-mailbox.c
> >index d1de07cc0ed62..006aa76b74b62 100644
> >--- a/drivers/mailbox/imx-mailbox.c
> >+++ b/drivers/mailbox/imx-mailbox.c
> >@@ -81,6 +81,7 @@ struct imx_mu_con_priv {
> > struct mbox_chan *chan;
> > struct work_struct txdb_work;
> > bool shutdown;
> >+ bool pending;
> > };
> >
> > struct imx_mu_priv {
> >@@ -539,11 +540,35 @@ static void imx_mu_txdb_work(struct work_struct *t)
> > mbox_chan_txdone(cp->chan, 0);
> > }
> >
> >+static irqreturn_t imx_mu_isr_th(int irq, void *p)
> >+{
> >+ struct mbox_chan *chan = p;
> >+ struct imx_mu_priv *priv = to_imx_mu_priv(chan->mbox);
> >+ struct imx_mu_con_priv *cp = chan->con_priv;
> >+
> >+ if (!cp->pending)
> >+ return IRQ_NONE;
>
> Is there a chance that cp->pending could be false here?
Maybe not. That handler is shared but the threaded handler is only woken
up if pending is set to true. So it should not observe it set to false.
You want me to get remove it?
> Regards
> Peng
Sebastian
More information about the linux-arm-kernel
mailing list