Skip to content

ASoC: SOF: Re-visit firmware state and panic tracking/handling

Peter Ujfalusi alsa-devel 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest20 patches 1 replyIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/20ASoC: SOF: ops: Use dev_warn() if the panic offsets differsound/soc/sof/ops.c+13 -80 replies
2/20ASoC: SOF: Intel: hda-loader: Avoid re-defining the HDA_FW_BOOT_ATTEMPTSsound/soc/sof/intel/hda-loader.c sound/soc/sof/intel/hda.h+1 -20 replies
3/20ASoC: SOF: core: Add simple wrapper to check flags in sof_core_debugsound/soc/sof/core.c sound/soc/sof/sof-priv.h+17 -00 replies
4/20ASoC: SOF: Use sof_debug_check_flag() instead of sof_core_debug directlysound/soc/sof/core.c sound/soc/sof/debug.c sound/soc/sof/sof-priv.h +1 more+11 -120 replies
5/20ASoC: SOF: Add 'non_recoverable' parameter to snd_sof_dsp_panic()sound/soc/sof/imx/imx8.c sound/soc/sof/imx/imx8m.c sound/soc/sof/intel/atom.c +6 more+66 -200 replies
6/20ASoC: SOF: Add a 'message' parameter to snd_sof_dsp_dbg_dump()sound/soc/sof/debug.c sound/soc/sof/intel/hda-loader.c sound/soc/sof/loader.c +2 more+23 -160 replies
7/20ASoC: SOF: Introduce new firmware state: SOF_FW_CRASHEDsound/soc/sof/debug.c sound/soc/sof/ipc.c sound/soc/sof/ops.c +2 more+12 -10 replies
8/20ASoC: SOF: Introduce new firmware state: SOF_FW_BOOT_READY_OKsound/soc/sof/debug.c sound/soc/sof/ipc.c sound/soc/sof/loader.c +1 more+7 -40 replies
9/20ASoC: SOF: Move the definition of enum snd_sof_fw_state to global headerinclude/sound/sof.h sound/soc/sof/sof-priv.h+22 -110 replies
10/20ASoC: SOF: Rename 'enum snd_sof_fw_state' to 'enum sof_fw_state'include/sound/sof.h sound/soc/sof/debug.c sound/soc/sof/sof-priv.h+5 -50 replies
11/20ASoC: SOF: ipc: Only allow sending of an IPC in SOF_FW_BOOT_COMPLETE statesound/soc/sof/ipc.c+1 -10 replies
12/20ASoC: SOF: Set SOF_FW_BOOT_FAILED in case we have failure during bootsound/soc/sof/core.c sound/soc/sof/loader.c sound/soc/sof/pm.c+4 -10 replies
13/20ASoC: SOF: pm: Force DSP off on suspend in BOOT_FAILED state alsosound/soc/sof/pm.c+4 -30 replies
14/20ASoc: SOF: core: Update the FW boot state transition diagramsound/soc/sof/core.c+26 -260 replies
15/20ASoC: SOF: ops: Always print DSP Panic message but use different messagesound/soc/sof/ops.c+11 -80 replies
16/20ASoC: SOF: dsp_arch_ops: add kernel log level parameter for oops and stacksound/soc/sof/core.c sound/soc/sof/sof-priv.h sound/soc/sof/xtensa/core.c+35 -280 replies
17/20ASoC: SOF: Rename snd_sof_get_status() and add kernel log level parametersound/soc/sof/core.c sound/soc/sof/imx/imx-common.c sound/soc/sof/intel/atom.c +3 more+40 -290 replies
18/20ASoC: SOF: Add clarifying comments for sof_core_debug and DSP dump flagssound/soc/sof/sof-priv.h+4 -20 replies
19/20ASoC: SOF: debug: Use DEBUG log level for optional printssound/soc/sof/debug.c+12 -80 replies
20/20ASoC: SOF: Intel: hda: Use DEBUG log level for optional printssound/soc/sof/intel/hda.c+10 -80 replies

Reviews trailers per patch

All 20 patches have a Reviewed-by or Acked-by.

PatchRanjani SridharanPierre-Louis BossartKai VehmanenPaul OlaruBard LiaoChao Song
1/20R-b R-b R-b
2/20R-b R-b R-b
3/20R-b R-b R-b
4/20R-b R-b R-b
5/20R-b R-b R-b
6/20R-b R-b R-b
7/20R-b R-b R-b R-b
8/20R-b R-b R-b R-b
9/20R-b R-b R-b R-b
10/20R-b R-b R-b R-b
11/20R-b R-b R-b
12/20R-b R-b R-b
13/20R-b R-b R-b
14/20R-b R-b R-b
15/20R-b R-b R-b R-b
16/20R-b R-b R-b R-b
17/20R-b R-b R-b R-b
18/20R-b R-b R-b R-b
19/20R-b R-b R-b R-b
20/20R-b R-b R-b R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes. Scroll the table sideways for all 6 reviewers.

Read the v1 thread

Cover letter [PATCH 00/20] ASoC: SOF: Re-visit firmware state and panic tracking/handling

Hi,

this series will improve how we are tracking the firmware's state to be able to avoid communication with it when it is not going to answer due to a panic and we will attempt to force power cycle the DSP to recover at the next runtime suspend time.

The state handling brings in other improvements on the way the kernel reports errors and DSP panics to reduce the printed lines for normal users, but at the same time allowing developers (or for bug reports) to have more precise information available to track down the issue.

We can now place messages easily in the correct debug level and not bound to the static ERROR for some of the print chains, causing excess amount or partial information to be printed, confusing users and machines (CI).

I would have prefered to split this series up, but it was developed together to achieve a single goal to reduce the noise, but also provide the details we need to be able to rootcause issues.

Regards,
Peter
---
Peter Ujfalusi (20):
ASoC: SOF: ops: Use dev_warn() if the panic offsets differ
ASoC: SOF: Intel: hda-loader: Avoid re-defining the
HDA_FW_BOOT_ATTEMPTS
ASoC: SOF: core: Add simple wrapper to check flags in sof_core_debug
ASoC: SOF: Use sof_debug_check_flag() instead of sof_core_debug
directly
ASoC: SOF: Add 'non_recoverable' parameter to snd_sof_dsp_panic()
ASoC: SOF: Add a 'message' parameter to snd_sof_dsp_dbg_dump()
ASoC: SOF: Introduce new firmware state: SOF_FW_CRASHED
ASoC: SOF: Introduce new firmware state: SOF_FW_BOOT_READY_OK
ASoC: SOF: Move the definition of enum snd_sof_fw_state to global
header
ASoC: SOF: Rename 'enum snd_sof_fw_state' to 'enum sof_fw_state'
ASoC: SOF: ipc: Only allow sending of an IPC in SOF_FW_BOOT_COMPLETE
state
ASoC: SOF: Set SOF_FW_BOOT_FAILED in case we have failure during boot
ASoC: SOF: pm: Force DSP off on suspend in BOOT_FAILED state also
ASoc: SOF: core: Update the FW boot state transition diagram
ASoC: SOF: ops: Always print DSP Panic message but use different
message
ASoC: SOF: dsp_arch_ops: add kernel log level parameter for oops and
stack
ASoC: SOF: Rename snd_sof_get_status() and add kernel log level
parameter
ASoC: SOF: Add clarifying comments for sof_core_debug and DSP dump
flags
ASoC: SOF: debug: Use DEBUG log level for optional prints
ASoC: SOF: Intel: hda: Use DEBUG log level for optional prints

 include/sound/sof.h              |  22 ++++++
 sound/soc/sof/core.c             | 119 +++++++++++++++++++------------
 sound/soc/sof/debug.c            |  35 +++++----
 sound/soc/sof/imx/imx-common.c   |   4 +-
 sound/soc/sof/imx/imx8.c         |   2 +-
 sound/soc/sof/imx/imx8m.c        |   2 +-
 sound/soc/sof/intel/atom.c       |   8 +--
 sound/soc/sof/intel/bdw.c        |   8 +--
 sound/soc/sof/intel/cnl.c        |  21 +++++-
 sound/soc/sof/intel/hda-ipc.c    |  19 ++++-
 sound/soc/sof/intel/hda-loader.c |  24 ++++---
 sound/soc/sof/intel/hda.c        |  20 +++---
 sound/soc/sof/intel/hda.h        |   2 +-
 sound/soc/sof/ipc.c              |   4 +-
 sound/soc/sof/loader.c           |  16 ++---
 sound/soc/sof/ops.c              |  47 ++++++++----
 sound/soc/sof/ops.h              |   4 +-
 sound/soc/sof/pm.c               |  10 +++
 sound/soc/sof/sof-priv.h         |  44 +++++-------
 sound/soc/sof/topology.c         |  12 ++--
 sound/soc/sof/xtensa/core.c      |  44 +++++++-----
 21 files changed, 299 insertions(+), 168 deletions(-)
Signature · 1 line
2.34.1