From: sashiko-bot@kernel.org
To: "Sebastian Andrzej Siewior" <bigeasy@linutronix.de>
Cc: imx@lists.linux.dev, Frank.Li@kernel.org
Subject: Re: [PATCH 3/5] mailbox: imx: Move the RXDB part of the mailbox into the threaded handler
Date: Fri, 29 May 2026 17:34:02 +0000 [thread overview]
Message-ID: <20260529173402.B8DE11F00893@smtp.kernel.org> (raw)
In-Reply-To: <20260529-imx_mbox_rproc-v1-3-b8ffc36e11e5@linutronix.de>
Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [High] Incorrect bitmask macro used when unmasking RXDB interrupts in the threaded IRQ handler.
--
commit 52f5529242040f4be31a0457d8d67afe5b6d8073
Author: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
mailbox: imx: Move the RXDB part of the mailbox into the threaded handler
This commit moves the RXDB callback handling into the threaded handler for
the i.MX mailbox driver. It unconditionally unmasks the RXDB interrupt in
the threaded handler after processing, similar to how the standard RX
interrupts are handled.
> diff --git a/drivers/mailbox/imx-mailbox.c b/drivers/mailbox/imx-mailbox.c
> --- a/drivers/mailbox/imx-mailbox.c
> +++ b/drivers/mailbox/imx-mailbox.c
[ ... ]
> @@ -528,6 +528,12 @@ static irqreturn_t imx_mu_isr_th(int irq, void *p)
> imx_mu_xcr_rmw(priv, IMX_MU_RCR, IMX_MU_xCR_RIEn(priv->dcfg->type, cp->idx), 0);
> return IRQ_HANDLED;
>
> + case IMX_MU_TYPE_RXDB:
> + cp->pending = 0;
> + priv->dcfg->rxdb(priv, cp);
> + imx_mu_xcr_rmw(priv, IMX_MU_GIER, IMX_MU_xCR_RIEn(priv->dcfg->type, cp->idx), 0);
[Severity: High]
Does this code use the correct bitmask macro for unmasking the RXDB interrupt?
The IMX_MU_TYPE_RXDB case appears to be using IMX_MU_xCR_RIEn (Receive
Interrupt Enable) instead of IMX_MU_xCR_GIEn (General Purpose Interrupt
Enable) to generate the bitmask.
On non-V2 hardware, these macros target different bit ranges (bits 24-27 for
RIEn vs bits 28-31 for GIEn). Could this leave the RXDB interrupt permanently
masked after it fires once, and inadvertently set incorrect bits in the
control register?
> + return IRQ_HANDLED;
> +
> default:
--
Sashiko AI review · https://sashiko.dev/#/patchset/20260529-imx_mbox_rproc-v1-0-b8ffc36e11e5@linutronix.de?part=3
next prev parent reply other threads:[~2026-05-29 17:34 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-05-29 16:01 [PATCH 0/5] mailbox: imx: Use threaded handler to avoid kworker in imx's remoteproc Sebastian Andrzej Siewior
2026-05-29 16:01 ` [PATCH 1/5] mailbox: imx: Start splitting the IRQ handler in primary and threaded handler Sebastian Andrzej Siewior
2026-05-29 16:43 ` sashiko-bot
2026-06-01 15:28 ` Sebastian Andrzej Siewior
2026-05-29 16:01 ` [PATCH 2/5] mailbox: imx: Move the RX part of the mailbox into the " Sebastian Andrzej Siewior
2026-05-29 17:26 ` sashiko-bot
2026-06-01 16:07 ` Sebastian Andrzej Siewior
2026-05-29 16:01 ` [PATCH 3/5] mailbox: imx: Move the RXDB " Sebastian Andrzej Siewior
2026-05-29 17:34 ` sashiko-bot [this message]
2026-06-01 16:15 ` Sebastian Andrzej Siewior
2026-05-29 16:01 ` [PATCH 4/5] mailbox: imx: Don't force-thread the primary handler Sebastian Andrzej Siewior
2026-05-29 18:13 ` sashiko-bot
2026-06-02 10:03 ` Sebastian Andrzej Siewior
2026-05-29 16:01 ` [PATCH 5/5] remoteproc: imx_rproc: Invoke the callback directly Sebastian Andrzej Siewior
2026-05-29 19:08 ` sashiko-bot
2026-06-02 12:11 ` Sebastian Andrzej Siewior
2026-06-02 16:51 ` [PATCH 0/5] mailbox: imx: Use threaded handler to avoid kworker in imx's remoteproc Mathieu Poirier
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260529173402.B8DE11F00893@smtp.kernel.org \
--to=sashiko-bot@kernel.org \
--cc=Frank.Li@kernel.org \
--cc=bigeasy@linutronix.de \
--cc=imx@lists.linux.dev \
--cc=sashiko-reviews@lists.linux.dev \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox