thesofproject / linux

Linux kernel source tree
Other
91 stars 134 forks source link

topology: error reported in sof_route_load on Linux 6.6.45+ #5147

Closed bannatech closed 3 months ago

bannatech commented 3 months ago

Recently, I had upgraded my kernel version to 6.6.45, and I run into a failure where the onboard speakers and microphone fail to load. The hardware is a Lenovo Thinkpad P1 Gen 6. I'm running nixos-stable 24.05.

My audio device is reported by inxi -A as Device-1: Intel Raptor Lake-P/U/H cAVS driver: sof-audio-pci-intel-tgl

The error messages appear either as a failure to find the sink, or the source. Each boot has a different garbled string being reported as the sink or the source.

An example log is listed below:

sof-audio-pci-intel-tgl 0000:00:1f.3: DSP detected with PCI class/subclass/prog-if info 0x040100
sof-audio-pci-intel-tgl 0000:00:1f.3: Digital mics found on Skylake+ platform, using SOF driver
sof-audio-pci-intel-tgl 0000:00:1f.3: DSP detected with PCI class/subclass/prog-if 0x040100
sof-audio-pci-intel-tgl 0000:00:1f.3: bound 0000:00:02.0 (ops i915_audio_component_bind_ops [i915])
sof-audio-pci-intel-tgl 0000:00:1f.3: use msi interrupt mode
sof-audio-pci-intel-tgl 0000:00:1f.3: hda codecs found, mask 5
sof-audio-pci-intel-tgl 0000:00:1f.3: using HDA machine driver skl_hda_dsp_generic now
sof-audio-pci-intel-tgl 0000:00:1f.3: DMICs detected in NHLT tables: 2
sof-audio-pci-intel-tgl 0000:00:1f.3: Firmware info: version 2:2:0-57864
sof-audio-pci-intel-tgl 0000:00:1f.3: Firmware: ABI 3:22:1 Kernel ABI 3:23:0
sof-audio-pci-intel-tgl 0000:00:1f.3: unknown sof_ext_man header type 3 size 0x30
sof-audio-pci-intel-tgl 0000:00:1f.3: Firmware info: version 2:2:0-57864
sof-audio-pci-intel-tgl 0000:00:1f.3: Firmware: ABI 3:22:1 Kernel ABI 3:23:0
sof-audio-pci-intel-tgl 0000:00:1f.3: Topology: ABI 3:22:1 Kernel ABI 3:23:0
sof-audio-pci-intel-tgl 0000:00:1f.3: error: sink MIXER1.0<8D>(<BA>;]<ED>1^_ not found
skl_hda_dsp_generic skl_hda_dsp_generic: ASoC: topology: add_route failed: -22
skl_hda_dsp_generic skl_hda_dsp_generic: ASoC: topology: could not load header: -22
sof-audio-pci-intel-tgl 0000:00:1f.3: error: tplg component load failed -22
sof-audio-pci-intel-tgl 0000:00:1f.3: error: failed to load DSP topology -22
sof-audio-pci-intel-tgl 0000:00:1f.3: ASoC: error at snd_soc_component_probe on 0000:00:1f.3: -22
skl_hda_dsp_generic skl_hda_dsp_generic: ASoC: failed to instantiate card -22
skl_hda_dsp_generic: probe of skl_hda_dsp_generic failed with error -22

DEVICE:
00:1f.3 Multimedia audio controller: Intel Corporation Raptor Lake-P/U/H cAVS (rev 01)
        Subsystem: Lenovo Device 2317
        Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B- DisINTx+
        Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort- <MAbort- >SERR- <PERR- INTx-
        Latency: 64
        Interrupt: pin A routed to IRQ 204
        IOMMU group: 13
        Region 0: Memory at 6452b30000 (64-bit, non-prefetchable) [size=16K]
        Region 4: Memory at 6452a00000 (64-bit, non-prefetchable) [size=1M]
        Kernel driver in use: sof-audio-pci-intel-tgl
        Kernel modules: snd_hda_intel, snd_sof_pci_intel_tgl

This error occurs repeatedly, and I do not experience this error on the kernel version 6.6.34

I'm glad to gather additional information, as I understand the nature of these issues can be very platform-specific and this might only pertain to a very small subset of users.

Thanks for any and all help!

EDIT: added example log inline

plbossart commented 3 months ago

known error fixed already in 6.6.47, please update your kernel.

Author: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com>  2024-06-13 11:01:26
Committer: Greg Kroah-Hartman <gregkh@linuxfoundation.org>  2024-08-19 06:04:22
Parent: bd865c7690020fb18e3f604f1b62706cfae289af (ASoC: topology: Clean up route loading)
Child:  9d91b004df9a6aa2487661e52a398fd808184955 (LoongArch: Define __ARCH_WANT_NEW_STAT in unistd.h)
Branches: remotes/stable/linux-6.6.y, remotes/stable/linux-rolling-lts
Follows: v6.6.46
Precedes: v6.6.47

    ASoC: topology: Fix route memory corruption

    commit 0298f51652be47b79780833e0b63194e1231fa34 upstream.

    It was reported that recent fix for memory corruption during topology
    load, causes corruption in other cases. Instead of being overeager with
    checking topology, assume that it is properly formatted and just
    duplicate strings.

    Reported-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
    Closes: https://lore.kernel.org/linux-sound/171812236450.201359.3019210915105428447.b4-ty@kernel.org/T/#m8c4bd5abf453960fde6f826c4b7f84881da63e9d
    Suggested-by: Péter Ujfalusi <peter.ujfalusi@linux.intel.com>
    Signed-off-by: Amadeusz Sławiński <amadeuszx.slawinski@linux.intel.com>
    Link: https://lore.kernel.org/r/20240613090126.841189-1-amadeuszx.slawinski@linux.intel.com
    Signed-off-by: Mark Brown <broonie@kernel.org>
    Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
bannatech commented 3 months ago

Thank you!