This is a note to let you know that I've just added the patch titled mailbox: imx: Clear the right interrupts at shutdown to the 5.4-stable tree which can be found at: http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary The filename of the patch is: mailbox-imx-clear-the-right-interrupts-at-shutdown.patch and it can be found in the queue-5.4 subdirectory. If you, or anyone else, feels it should not be added to the stable tree, please let <stable@xxxxxxxxxxxxxxx> know about it. commit 79b85e7ebb897a2759139bb7ab239061ed738780 Author: Daniel Baluta <daniel.baluta@xxxxxxx> Date: Wed Oct 9 16:07:19 2019 +0800 mailbox: imx: Clear the right interrupts at shutdown [ Upstream commit 5f0af07e89199ac51cdd4f25bc303bdc703f4e9c ] Make sure to only clear enabled interrupts keeping count of the connection type. Suggested-by: Oleksij Rempel <o.rempel@xxxxxxxxxxxxxx> Signed-off-by: Daniel Baluta <daniel.baluta@xxxxxxx> Signed-off-by: Richard Zhu <hongxing.zhu@xxxxxxx> Reviewed-by: Dong Aisheng <aisheng.dong@xxxxxxx> Signed-off-by: Jassi Brar <jaswinder.singh@xxxxxxxxxx> Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx> diff --git a/drivers/mailbox/imx-mailbox.c b/drivers/mailbox/imx-mailbox.c index 9f74dee1a58c..d28bbd47ff88 100644 --- a/drivers/mailbox/imx-mailbox.c +++ b/drivers/mailbox/imx-mailbox.c @@ -217,8 +217,19 @@ static void imx_mu_shutdown(struct mbox_chan *chan) if (cp->type == IMX_MU_TYPE_TXDB) tasklet_kill(&cp->txdb_tasklet); - imx_mu_xcr_rmw(priv, 0, IMX_MU_xCR_TIEn(cp->idx) | - IMX_MU_xCR_RIEn(cp->idx) | IMX_MU_xCR_GIEn(cp->idx)); + switch (cp->type) { + case IMX_MU_TYPE_TX: + imx_mu_xcr_rmw(priv, 0, IMX_MU_xCR_TIEn(cp->idx)); + break; + case IMX_MU_TYPE_RX: + imx_mu_xcr_rmw(priv, 0, IMX_MU_xCR_RIEn(cp->idx)); + break; + case IMX_MU_TYPE_RXDB: + imx_mu_xcr_rmw(priv, 0, IMX_MU_xCR_GIEn(cp->idx)); + break; + default: + break; + } free_irq(priv->irq, chan); }