All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] ASoC: fsl_xcvr: disable all interrupts when suspend happens
@ 2021-06-18  9:51 Shengjiu Wang
  2021-06-18 11:20   ` Fabio Estevam
  2021-06-21 18:46 ` Mark Brown
  0 siblings, 2 replies; 9+ messages in thread
From: Shengjiu Wang @ 2021-06-18  9:51 UTC (permalink / raw)
  To: timur, nicoleotsuka, Xiubo.Lee, festevam, broonie, perex, tiwai,
	alsa-devel
  Cc: linuxppc-dev, linux-kernel

There is an unhandled interrupt after suspend, which cause endless
interrupt when system resume, so system may hang.

Disable all interrupts in runtime suspend callback to avoid above
issue.

Signed-off-by: Shengjiu Wang <shengjiu.wang@nxp.com>
---
 sound/soc/fsl/fsl_xcvr.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/sound/soc/fsl/fsl_xcvr.c b/sound/soc/fsl/fsl_xcvr.c
index df7c189d97dd..37b4fdb236ee 100644
--- a/sound/soc/fsl/fsl_xcvr.c
+++ b/sound/soc/fsl/fsl_xcvr.c
@@ -1233,6 +1233,11 @@ static __maybe_unused int fsl_xcvr_runtime_suspend(struct device *dev)
 	struct fsl_xcvr *xcvr = dev_get_drvdata(dev);
 	int ret;
 
+	ret = regmap_update_bits(xcvr->regmap, FSL_XCVR_EXT_IER0,
+				 FSL_XCVR_IRQ_EARC_ALL, 0);
+	if (ret < 0)
+		dev_err(dev, "Failed to clear IER0: %d\n", ret);
+
 	/* Assert M0+ reset */
 	ret = regmap_update_bits(xcvr->regmap, FSL_XCVR_EXT_CTRL,
 				 FSL_XCVR_EXT_CTRL_CORE_RESET,
-- 
2.27.0


^ permalink raw reply related	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2021-06-21 18:47 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-06-18  9:51 [PATCH] ASoC: fsl_xcvr: disable all interrupts when suspend happens Shengjiu Wang
2021-06-18 11:20 ` Fabio Estevam
2021-06-18 11:20   ` Fabio Estevam
2021-06-18 11:20   ` Fabio Estevam
2021-06-18 11:30   ` Shengjiu Wang
2021-06-18 11:30     ` Shengjiu Wang
2021-06-18 11:33     ` Mark Brown
2021-06-18 11:33       ` Mark Brown
2021-06-21 18:46 ` Mark Brown

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.