diff options
author | Peter Ujfalusi <[email protected]> | 2021-12-23 13:36:21 +0200 |
---|---|---|
committer | Mark Brown <[email protected]> | 2021-12-23 13:38:22 +0000 |
commit | b54b3a4e08bc0210768a1839af2ff888376cae4c (patch) | |
tree | 84c86e40fe19f678aa6e924cbb8e805945612589 | |
parent | e2406275be2b6b15d985f33aec921e6555e4f87a (diff) |
ASoC: SOF: pm: Force DSP off on suspend in BOOT_FAILED state also
Try to force the DSP to be turned off next time if the fw_state is either
CRASHED or BOOT_FAILED when a suspend happens in order to attempt a clean
boot to recover.
Signed-off-by: Peter Ujfalusi <[email protected]>
Reviewed-by: Pierre-Louis Bossart <[email protected]>
Reviewed-by: Bard Liao <[email protected]>
Reviewed-by: Ranjani Sridharan <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Mark Brown <[email protected]>
-rw-r--r-- | sound/soc/sof/pm.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/sound/soc/sof/pm.c b/sound/soc/sof/pm.c index 022b19669735..197a88695fef 100644 --- a/sound/soc/sof/pm.c +++ b/sound/soc/sof/pm.c @@ -315,10 +315,11 @@ int snd_sof_prepare(struct device *dev) sdev->system_suspend_target = SOF_SUSPEND_S3; /* - * if the firmware is crashed then we try to aim for S3 to reboot the - * firmware + * if the firmware is crashed or boot failed then we try to aim for S3 + * to reboot the firmware */ - if (sdev->fw_state == SOF_FW_CRASHED) + if (sdev->fw_state == SOF_FW_CRASHED || + sdev->fw_state == SOF_FW_BOOT_FAILED) return 0; if (!desc->use_acpi_target_states) |