[PATCH 1/2] ASoC: SDCA: Set suspended flag after resuming within system suspend

From: Maciej Strozek

Date: Thu Sep 24 2026 - 06:04:33 EST


drv->suspended path was executed before system suspension instead of
after, move it lower to correct it.

Fixes: 7a5214f769c7 ("ASoC: SDCA: Add basic system suspend support")
Signed-off-by: Maciej Strozek <mstrozek@xxxxxxxxxxxxxxxxxxxxx>
---
sound/soc/sdca/sdca_class_function.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/sound/soc/sdca/sdca_class_function.c b/sound/soc/sdca/sdca_class_function.c
index 1d7fd66038829..1a7167aafa910 100644
--- a/sound/soc/sdca/sdca_class_function.c
+++ b/sound/soc/sdca/sdca_class_function.c
@@ -491,8 +491,6 @@ static int class_function_suspend(struct device *dev)
struct class_function_drv *drv = auxiliary_get_drvdata(auxdev);
int ret;

- drv->suspended = true;
-
/* Ensure runtime resume runs on resume */
ret = pm_runtime_resume_and_get(dev);
if (ret) {
@@ -500,6 +498,8 @@ static int class_function_suspend(struct device *dev)
return ret;
}

+ drv->suspended = true;
+
sdca_irq_disable(drv->function, drv->core->irq_info);

ret = pm_runtime_force_suspend(dev);
--
2.47.3