]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
reset: imx8mp-audiomix: Add support for DSP run/stall
authorDaniel Baluta <daniel.baluta@nxp.com>
Tue, 11 Mar 2025 08:58:10 +0000 (10:58 +0200)
committerMathieu Poirier <mathieu.poirier@linaro.org>
Thu, 13 Mar 2025 15:10:33 +0000 (09:10 -0600)
We can Run/Stall the DSP via audio block control bits found in audiomix.
Implement this functionality using the reset controller and use assert
for Stall and deassert for Run.

Reviewed-by: Peng Fan <peng.fan@nxp.com>
Reviewed-by: Frank Li <Frank.Li@nxp.com>
Signed-off-by: Daniel Baluta <daniel.baluta@nxp.com>
Reviewed-by: Philipp Zabel <p.zabel@pengutronix.de>
Link: https://lore.kernel.org/r/20250311085812.1296243-8-daniel.baluta@nxp.com
Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org>
drivers/reset/reset-imx8mp-audiomix.c

index 04ad27aca806b2c7560f9d3adab2d590a0dc48f4..6b357adfe646c755407875ecd963a8d304d81bef 100644 (file)
@@ -17,6 +17,9 @@
 #define IMX8MP_AUDIOMIX_EARC_RESET_MASK                BIT(1)
 #define IMX8MP_AUDIOMIX_EARC_PHY_RESET_MASK    BIT(2)
 
+#define IMX8MP_AUDIOMIX_DSP_RUNSTALL_OFFSET    0x108
+#define IMX8MP_AUDIOMIX_DSP_RUNSTALL_MASK      BIT(5)
+
 struct imx8mp_reset_map {
        unsigned int offset;
        unsigned int mask;
@@ -34,6 +37,11 @@ static const struct imx8mp_reset_map reset_map[] = {
                .mask   = IMX8MP_AUDIOMIX_EARC_PHY_RESET_MASK,
                .active_low = true,
        },
+       [IMX8MP_AUDIOMIX_DSP_RUNSTALL] = {
+               .offset = IMX8MP_AUDIOMIX_DSP_RUNSTALL_OFFSET,
+               .mask   = IMX8MP_AUDIOMIX_DSP_RUNSTALL_MASK,
+               .active_low = false,
+       },
 };
 
 struct imx8mp_audiomix_reset {