Since: 83bfc7e793b5 ("ASoC: SOF: core: unregister clients and machine drivers 
in .shutdown")
we wait for all the workloads to be completed during shutdown. This was done to 
avoid a stall once the device is started again.

Unfortunately this has the side effect of stalling kexec(), if the userspace
is frozen. Let's handle that case.

To: Pierre-Louis Bossart <[email protected]>
To: Liam Girdwood <[email protected]>
To: Peter Ujfalusi <[email protected]>
To: Bard Liao <[email protected]>
To: Ranjani Sridharan <[email protected]>
To: Kai Vehmanen <[email protected]>
To: Daniel Baluta <[email protected]>
To: Mark Brown <[email protected]>
To: Jaroslav Kysela <[email protected]>
To: Takashi Iwai <[email protected]>
To: Eric Biederman <[email protected]>
To: Chromeos Kdump <[email protected]>
To: Steven Rostedt <[email protected]>
Cc: [email protected]
Cc: [email protected]
Cc: [email protected]
Cc: [email protected]
Cc: [email protected]
Signed-off-by: Ricardo Ribalda <[email protected]>
---
Changes in v6:
- Check if we are in kexec with the userspace frozen.
- Link to v5: 
https://lore.kernel.org/r/[email protected]

Changes in v5:
- Edit subject prefix.
- Link to v4: 
https://lore.kernel.org/r/[email protected]

Changes in v4:
- Do not call snd_sof_machine_unregister from shutdown.
- Link to v3: 
https://lore.kernel.org/r/[email protected]

Changes in v3:
- Wrap pm_freezing in a function.
- Link to v2: 
https://lore.kernel.org/r/[email protected]

Changes in v2:
- Only use pm_freezing if CONFIG_FREEZER .
- Link to v1: 
https://lore.kernel.org/r/[email protected]

---
Ricardo Ribalda (2):
      kexec: Introduce kexec_with_frozen_processes
      ASoC: SOF: Fix deadlock when shutdown a frozen userspace

 include/linux/kexec.h | 3 +++
 kernel/kexec_core.c   | 5 +++++
 sound/soc/sof/core.c  | 4 +++-
 3 files changed, 11 insertions(+), 1 deletion(-)
---
base-commit: 4312098baf37ee17a8350725e6e0d0e8590252d4
change-id: 20221127-snd-freeze-1ee143228326

Best regards,
-- 
Ricardo Ribalda <[email protected]>

_______________________________________________
kexec mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/kexec

Reply via email to