linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* No sound cards detected on Kabylake laptops after upgrade to kernel 5.8
@ 2021-03-09 12:19 Chris Chiu
  2021-03-09 15:29 ` Cezary Rojewski
  0 siblings, 1 reply; 7+ messages in thread
From: Chris Chiu @ 2021-03-09 12:19 UTC (permalink / raw)
  To: pierre-louis.bossart, cezary.rojewski, liam.r.girdwood, yang.jie,
	broonie, Takashi Iwai
  Cc: alsa-devel, Linux Kernel

Hi Guys,
    We have received reports that on some Kabylake laptops (Acer Swift
SF314-54/55 and Lenovo Yoga C930...etc), all sound cards no longer be
detected after upgrade to kernel later than 5.8. These laptops have
one thing in common, all of them have Realtek audio codec and connect
the internal microphone to DMIC of the Intel SST controller either
[8086:9d71] or [8086:9dc8]. Please refer to
https://bugzilla.kernel.org/show_bug.cgi?id=201251#c246 and
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1915117.

    From the dmesg from kernel 5.8, the sound related parts only show
as follows but the expected snd_hda_codec_realtek and the snd_soc_skl
are not even loaded then.
[ 13.357495] snd_hda_intel 0000:00:1f.3: DSP detected with PCI
class/subclass/prog-if info 0x040100
[ 13.357500] snd_hda_intel 0000:00:1f.3: Digital mics found on
Skylake+ platform, using SST driver

    Building the kernel with the CONFIG_SND_SOC_INTEL_KBL removed can
load the snd_hda_codec_realtek successfully and the pulseaudio and
alsa-utils can detect the sound cards again. The result of bisecting
between kernel 5.4 and 5.8 also get similar result, reverting the
commit "ALSA: hda: Allow SST driver on SKL and KBL platforms with
DMIC" can fix the issue. I tried to generate the required firmware for
snd_soc_skl but it did not help. Please refer to what I did in
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1915117/comments/14
and https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1915117/comments/18.

    Since the skl_hda_dsp_generic-tplg.bin and dfw_sst.bin are not in
the linux-firmware. The Intel SST support for Skylake family is not
yet complete. Can we simply revert the "ALSA: hda: Allow SST driver on
SKL and KBL platforms with DMIC" in the current stage and wait for SOF
support for Skylake family? Or please suggest a better solution for
this. Thanks

Chris

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: No sound cards detected on Kabylake laptops after upgrade to kernel 5.8
  2021-03-09 12:19 No sound cards detected on Kabylake laptops after upgrade to kernel 5.8 Chris Chiu
@ 2021-03-09 15:29 ` Cezary Rojewski
  2021-03-11  5:50   ` Chris Chiu
  0 siblings, 1 reply; 7+ messages in thread
From: Cezary Rojewski @ 2021-03-09 15:29 UTC (permalink / raw)
  To: Chris Chiu, pierre-louis.bossart, liam.r.girdwood, yang.jie,
	broonie, Takashi Iwai
  Cc: alsa-devel, Linux Kernel

On 2021-03-09 1:19 PM, Chris Chiu wrote:
> Hi Guys,
>      We have received reports that on some Kabylake laptops (Acer Swift
> SF314-54/55 and Lenovo Yoga C930...etc), all sound cards no longer be
> detected after upgrade to kernel later than 5.8. These laptops have
> one thing in common, all of them have Realtek audio codec and connect
> the internal microphone to DMIC of the Intel SST controller either
> [8086:9d71] or [8086:9dc8]. Please refer to
> https://bugzilla.kernel.org/show_bug.cgi?id=201251#c246 and
> https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1915117.
> 
>      From the dmesg from kernel 5.8, the sound related parts only show
> as follows but the expected snd_hda_codec_realtek and the snd_soc_skl
> are not even loaded then.
> [ 13.357495] snd_hda_intel 0000:00:1f.3: DSP detected with PCI
> class/subclass/prog-if info 0x040100
> [ 13.357500] snd_hda_intel 0000:00:1f.3: Digital mics found on
> Skylake+ platform, using SST driver
> 
>      Building the kernel with the CONFIG_SND_SOC_INTEL_KBL removed can
> load the snd_hda_codec_realtek successfully and the pulseaudio and
> alsa-utils can detect the sound cards again. The result of bisecting
> between kernel 5.4 and 5.8 also get similar result, reverting the
> commit "ALSA: hda: Allow SST driver on SKL and KBL platforms with
> DMIC" can fix the issue. I tried to generate the required firmware for
> snd_soc_skl but it did not help. Please refer to what I did in
> https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1915117/comments/14
> and https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1915117/comments/18.
> 
>      Since the skl_hda_dsp_generic-tplg.bin and dfw_sst.bin are not in
> the linux-firmware. The Intel SST support for Skylake family is not
> yet complete. Can we simply revert the "ALSA: hda: Allow SST driver on
> SKL and KBL platforms with DMIC" in the current stage and wait for SOF
> support for Skylake family? Or please suggest a better solution for
> this. Thanks
> 
> Chris
> 

Hello Chris,

Guide: "Linux: HDA+DMIC with skylake driver" [1] should help 
understanding history behind the problem as well as fixing it.

Upstream skylake driver - snd_soc_skl - is intended to support HDA DSP + 
DMIC configuration via means of snd_soc_skl_hda_dsp machine board 
driver. You _may_ switch to legacy HDAudio driver - snd_hda_intel - 
losing DMIC support in the process. To remove any confusion - for 
Skylake and Kabylake platforms, snd_soc_skl is your option.

Now, due to above, I doubt any skylake-related topology has ever been 
upstreamed to linux-firmware as a) most boards are I2S-based, these are 
used by our clients which we support via separate channel b) hda 
dsp+dmic support on linux for missing until early 2020.

Topologies for most common skylake driver configurations:
- skl/kbl with i2s rt286
- apl/glk with i2s rt298
- <any> with hda dsp
can be found in alsa-topology-conf [2].

Standard, official tool called 'alsatplg' is capable of compiling these 
into binary form which, after being transferred to /lib/firmware/ may be 
consumed by the driver during runtime.
I have no problem with providing precompiled binaries to linux-firmware, 
if that's what community wants.

Regards,
Czarek


[1]: https://gist.github.com/crojewsk/4e6382bfb0dbfaaf60513174211f29cb
[2]: https://github.com/alsa-project/alsa-topology-conf/tree/master/topology

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: No sound cards detected on Kabylake laptops after upgrade to kernel 5.8
  2021-03-09 15:29 ` Cezary Rojewski
@ 2021-03-11  5:50   ` Chris Chiu
  2021-03-11  7:58     ` Cezary Rojewski
  2021-03-11 10:24     ` Jaroslav Kysela
  0 siblings, 2 replies; 7+ messages in thread
From: Chris Chiu @ 2021-03-11  5:50 UTC (permalink / raw)
  To: Cezary Rojewski
  Cc: pierre-louis.bossart, liam.r.girdwood, yang.jie, broonie,
	Takashi Iwai, alsa-devel, Linux Kernel

On Tue, Mar 9, 2021 at 11:29 PM Cezary Rojewski
<cezary.rojewski@intel.com> wrote:
>
> On 2021-03-09 1:19 PM, Chris Chiu wrote:
> > Hi Guys,
> >      We have received reports that on some Kabylake laptops (Acer Swift
> > SF314-54/55 and Lenovo Yoga C930...etc), all sound cards no longer be
> > detected after upgrade to kernel later than 5.8. These laptops have
> > one thing in common, all of them have Realtek audio codec and connect
> > the internal microphone to DMIC of the Intel SST controller either
> > [8086:9d71] or [8086:9dc8]. Please refer to
> > https://bugzilla.kernel.org/show_bug.cgi?id=201251#c246 and
> > https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1915117.
> >
> >      From the dmesg from kernel 5.8, the sound related parts only show
> > as follows but the expected snd_hda_codec_realtek and the snd_soc_skl
> > are not even loaded then.
> > [ 13.357495] snd_hda_intel 0000:00:1f.3: DSP detected with PCI
> > class/subclass/prog-if info 0x040100
> > [ 13.357500] snd_hda_intel 0000:00:1f.3: Digital mics found on
> > Skylake+ platform, using SST driver
> >
> >      Building the kernel with the CONFIG_SND_SOC_INTEL_KBL removed can
> > load the snd_hda_codec_realtek successfully and the pulseaudio and
> > alsa-utils can detect the sound cards again. The result of bisecting
> > between kernel 5.4 and 5.8 also get similar result, reverting the
> > commit "ALSA: hda: Allow SST driver on SKL and KBL platforms with
> > DMIC" can fix the issue. I tried to generate the required firmware for
> > snd_soc_skl but it did not help. Please refer to what I did in
> > https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1915117/comments/14
> > and https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1915117/comments/18.
> >
> >      Since the skl_hda_dsp_generic-tplg.bin and dfw_sst.bin are not in
> > the linux-firmware. The Intel SST support for Skylake family is not
> > yet complete. Can we simply revert the "ALSA: hda: Allow SST driver on
> > SKL and KBL platforms with DMIC" in the current stage and wait for SOF
> > support for Skylake family? Or please suggest a better solution for
> > this. Thanks
> >
> > Chris
> >
>
> Hello Chris,
>
> Guide: "Linux: HDA+DMIC with skylake driver" [1] should help
> understanding history behind the problem as well as fixing it.
>
> Upstream skylake driver - snd_soc_skl - is intended to support HDA DSP +
> DMIC configuration via means of snd_soc_skl_hda_dsp machine board
> driver. You _may_ switch to legacy HDAudio driver - snd_hda_intel -
> losing DMIC support in the process. To remove any confusion - for
> Skylake and Kabylake platforms, snd_soc_skl is your option.
>
> Now, due to above, I doubt any skylake-related topology has ever been
> upstreamed to linux-firmware as a) most boards are I2S-based, these are
> used by our clients which we support via separate channel b) hda
> dsp+dmic support on linux for missing until early 2020.
>
> Topologies for most common skylake driver configurations:
> - skl/kbl with i2s rt286
> - apl/glk with i2s rt298
> - <any> with hda dsp
> can be found in alsa-topology-conf [2].
>
> Standard, official tool called 'alsatplg' is capable of compiling these
> into binary form which, after being transferred to /lib/firmware/ may be
> consumed by the driver during runtime.
> I have no problem with providing precompiled binaries to linux-firmware,
> if that's what community wants.
>
> Regards,
> Czarek
>
>

I think the guild [1] is too complicated for normal users to fix the problem.
Given it's not only the internal microphone being affected, it's no sound
devices being created at all so no audio functions can work after kernel 5.8.

Is there any potential problem to built-in the "<any> with hda dsp" precompiled
binary in linux-firmware?

Chris

> [1]: https://gist.github.com/crojewsk/4e6382bfb0dbfaaf60513174211f29cb
> [2]: https://github.com/alsa-project/alsa-topology-conf/tree/master/topology

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: No sound cards detected on Kabylake laptops after upgrade to kernel 5.8
  2021-03-11  5:50   ` Chris Chiu
@ 2021-03-11  7:58     ` Cezary Rojewski
  2021-03-11 10:24     ` Jaroslav Kysela
  1 sibling, 0 replies; 7+ messages in thread
From: Cezary Rojewski @ 2021-03-11  7:58 UTC (permalink / raw)
  To: Chris Chiu
  Cc: pierre-louis.bossart, liam.r.girdwood, yang.jie, broonie,
	Takashi Iwai, alsa-devel, Linux Kernel

On 2021-03-11 6:50 AM, Chris Chiu wrote:
> On Tue, Mar 9, 2021 at 11:29 PM Cezary Rojewski
> <cezary.rojewski@intel.com> wrote:
>>

...

>> Topologies for most common skylake driver configurations:
>> - skl/kbl with i2s rt286
>> - apl/glk with i2s rt298
>> - <any> with hda dsp
>> can be found in alsa-topology-conf [2].
>>
>> Standard, official tool called 'alsatplg' is capable of compiling these
>> into binary form which, after being transferred to /lib/firmware/ may be
>> consumed by the driver during runtime.
>> I have no problem with providing precompiled binaries to linux-firmware,
>> if that's what community wants.

...

> 
> I think the guild [1] is too complicated for normal users to fix the problem.
> Given it's not only the internal microphone being affected, it's no sound
> devices being created at all so no audio functions can work after kernel 5.8.
> 
> Is there any potential problem to built-in the "<any> with hda dsp" precompiled
> binary in linux-firmware?

In general, linux-firmware is not the place to put driver-specific 
configuration files. It'd best to have standard UCM/topology files being 
build and honored during disto image creation.

In regard to the guide, thanks for checking it out. What do you think 
could be improved so that normal user has easier time with it? Feedback 
is much appreciated.

Regards,
Czarek

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: No sound cards detected on Kabylake laptops after upgrade to kernel 5.8
  2021-03-11  5:50   ` Chris Chiu
  2021-03-11  7:58     ` Cezary Rojewski
@ 2021-03-11 10:24     ` Jaroslav Kysela
  2021-03-11 10:40       ` Amadeusz Sławiński
  1 sibling, 1 reply; 7+ messages in thread
From: Jaroslav Kysela @ 2021-03-11 10:24 UTC (permalink / raw)
  To: Chris Chiu, Cezary Rojewski
  Cc: alsa-devel, Linux Kernel, yang.jie, pierre-louis.bossart,
	Takashi Iwai, liam.r.girdwood, broonie

Dne 11. 03. 21 v 6:50 Chris Chiu napsal(a):
> On Tue, Mar 9, 2021 at 11:29 PM Cezary Rojewski
> <cezary.rojewski@intel.com> wrote:
>>
>> On 2021-03-09 1:19 PM, Chris Chiu wrote:
>>> Hi Guys,
>>>      We have received reports that on some Kabylake laptops (Acer Swift
>>> SF314-54/55 and Lenovo Yoga C930...etc), all sound cards no longer be
>>> detected after upgrade to kernel later than 5.8. These laptops have
>>> one thing in common, all of them have Realtek audio codec and connect
>>> the internal microphone to DMIC of the Intel SST controller either
>>> [8086:9d71] or [8086:9dc8]. Please refer to
>>> https://bugzilla.kernel.org/show_bug.cgi?id=201251#c246 and
>>> https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1915117.
>>>
>>>      From the dmesg from kernel 5.8, the sound related parts only show
>>> as follows but the expected snd_hda_codec_realtek and the snd_soc_skl
>>> are not even loaded then.
>>> [ 13.357495] snd_hda_intel 0000:00:1f.3: DSP detected with PCI
>>> class/subclass/prog-if info 0x040100
>>> [ 13.357500] snd_hda_intel 0000:00:1f.3: Digital mics found on
>>> Skylake+ platform, using SST driver
>>>
>>>      Building the kernel with the CONFIG_SND_SOC_INTEL_KBL removed can
>>> load the snd_hda_codec_realtek successfully and the pulseaudio and
>>> alsa-utils can detect the sound cards again. The result of bisecting
>>> between kernel 5.4 and 5.8 also get similar result, reverting the
>>> commit "ALSA: hda: Allow SST driver on SKL and KBL platforms with
>>> DMIC" can fix the issue. I tried to generate the required firmware for
>>> snd_soc_skl but it did not help. Please refer to what I did in
>>> https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1915117/comments/14
>>> and https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1915117/comments/18.
>>>
>>>      Since the skl_hda_dsp_generic-tplg.bin and dfw_sst.bin are not in
>>> the linux-firmware. The Intel SST support for Skylake family is not
>>> yet complete. Can we simply revert the "ALSA: hda: Allow SST driver on
>>> SKL and KBL platforms with DMIC" in the current stage and wait for SOF
>>> support for Skylake family? Or please suggest a better solution for
>>> this. Thanks
>>>
>>> Chris
>>>
>>
>> Hello Chris,
>>
>> Guide: "Linux: HDA+DMIC with skylake driver" [1] should help
>> understanding history behind the problem as well as fixing it.
>>
>> Upstream skylake driver - snd_soc_skl - is intended to support HDA DSP +
>> DMIC configuration via means of snd_soc_skl_hda_dsp machine board
>> driver. You _may_ switch to legacy HDAudio driver - snd_hda_intel -
>> losing DMIC support in the process. To remove any confusion - for
>> Skylake and Kabylake platforms, snd_soc_skl is your option.
>>
>> Now, due to above, I doubt any skylake-related topology has ever been
>> upstreamed to linux-firmware as a) most boards are I2S-based, these are
>> used by our clients which we support via separate channel b) hda
>> dsp+dmic support on linux for missing until early 2020.
>>
>> Topologies for most common skylake driver configurations:
>> - skl/kbl with i2s rt286
>> - apl/glk with i2s rt298
>> - <any> with hda dsp
>> can be found in alsa-topology-conf [2].
>>
>> Standard, official tool called 'alsatplg' is capable of compiling these
>> into binary form which, after being transferred to /lib/firmware/ may be
>> consumed by the driver during runtime.
>> I have no problem with providing precompiled binaries to linux-firmware,
>> if that's what community wants.
>>
>> Regards,
>> Czarek
>>
>>
> 
> I think the guild [1] is too complicated for normal users to fix the problem.
> Given it's not only the internal microphone being affected, it's no sound
> devices being created at all so no audio functions can work after kernel 5.8.
> 
> Is there any potential problem to built-in the "<any> with hda dsp" precompiled
> binary in linux-firmware?

How do you distribute the SOF firmware? I'm going to include those binary
topology files to the SOF firmware package for Fedora. Perhaps, you may follow
this.

					Jaroslav

> 
> Chris
> 
>> [1]: https://gist.github.com/crojewsk/4e6382bfb0dbfaaf60513174211f29cb
>> [2]: https://github.com/alsa-project/alsa-topology-conf/tree/master/topology


-- 
Jaroslav Kysela <perex@perex.cz>
Linux Sound Maintainer; ALSA Project; Red Hat, Inc.

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: No sound cards detected on Kabylake laptops after upgrade to kernel 5.8
  2021-03-11 10:24     ` Jaroslav Kysela
@ 2021-03-11 10:40       ` Amadeusz Sławiński
  2021-03-11 14:10         ` Jaroslav Kysela
  0 siblings, 1 reply; 7+ messages in thread
From: Amadeusz Sławiński @ 2021-03-11 10:40 UTC (permalink / raw)
  To: Jaroslav Kysela, Chris Chiu, Cezary Rojewski
  Cc: pierre-louis.bossart, alsa-devel, yang.jie, Takashi Iwai,
	Linux Kernel, liam.r.girdwood, broonie

On 3/11/2021 11:24 AM, Jaroslav Kysela wrote:
> Dne 11. 03. 21 v 6:50 Chris Chiu napsal(a):
>> On Tue, Mar 9, 2021 at 11:29 PM Cezary Rojewski
>> <cezary.rojewski@intel.com> wrote:
>>>
>>> On 2021-03-09 1:19 PM, Chris Chiu wrote:
>>>> Hi Guys,
>>>>       We have received reports that on some Kabylake laptops (Acer Swift
>>>> SF314-54/55 and Lenovo Yoga C930...etc), all sound cards no longer be
>>>> detected after upgrade to kernel later than 5.8. These laptops have
>>>> one thing in common, all of them have Realtek audio codec and connect
>>>> the internal microphone to DMIC of the Intel SST controller either
>>>> [8086:9d71] or [8086:9dc8]. Please refer to
>>>> https://bugzilla.kernel.org/show_bug.cgi?id=201251#c246 and
>>>> https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1915117.
>>>>
>>>>       From the dmesg from kernel 5.8, the sound related parts only show
>>>> as follows but the expected snd_hda_codec_realtek and the snd_soc_skl
>>>> are not even loaded then.
>>>> [ 13.357495] snd_hda_intel 0000:00:1f.3: DSP detected with PCI
>>>> class/subclass/prog-if info 0x040100
>>>> [ 13.357500] snd_hda_intel 0000:00:1f.3: Digital mics found on
>>>> Skylake+ platform, using SST driver
>>>>
>>>>       Building the kernel with the CONFIG_SND_SOC_INTEL_KBL removed can
>>>> load the snd_hda_codec_realtek successfully and the pulseaudio and
>>>> alsa-utils can detect the sound cards again. The result of bisecting
>>>> between kernel 5.4 and 5.8 also get similar result, reverting the
>>>> commit "ALSA: hda: Allow SST driver on SKL and KBL platforms with
>>>> DMIC" can fix the issue. I tried to generate the required firmware for
>>>> snd_soc_skl but it did not help. Please refer to what I did in
>>>> https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1915117/comments/14
>>>> and https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1915117/comments/18.
>>>>
>>>>       Since the skl_hda_dsp_generic-tplg.bin and dfw_sst.bin are not in
>>>> the linux-firmware. The Intel SST support for Skylake family is not
>>>> yet complete. Can we simply revert the "ALSA: hda: Allow SST driver on
>>>> SKL and KBL platforms with DMIC" in the current stage and wait for SOF
>>>> support for Skylake family? Or please suggest a better solution for
>>>> this. Thanks
>>>>
>>>> Chris
>>>>
>>>
>>> Hello Chris,
>>>
>>> Guide: "Linux: HDA+DMIC with skylake driver" [1] should help
>>> understanding history behind the problem as well as fixing it.
>>>
>>> Upstream skylake driver - snd_soc_skl - is intended to support HDA DSP +
>>> DMIC configuration via means of snd_soc_skl_hda_dsp machine board
>>> driver. You _may_ switch to legacy HDAudio driver - snd_hda_intel -
>>> losing DMIC support in the process. To remove any confusion - for
>>> Skylake and Kabylake platforms, snd_soc_skl is your option.
>>>
>>> Now, due to above, I doubt any skylake-related topology has ever been
>>> upstreamed to linux-firmware as a) most boards are I2S-based, these are
>>> used by our clients which we support via separate channel b) hda
>>> dsp+dmic support on linux for missing until early 2020.
>>>
>>> Topologies for most common skylake driver configurations:
>>> - skl/kbl with i2s rt286
>>> - apl/glk with i2s rt298
>>> - <any> with hda dsp
>>> can be found in alsa-topology-conf [2].
>>>
>>> Standard, official tool called 'alsatplg' is capable of compiling these
>>> into binary form which, after being transferred to /lib/firmware/ may be
>>> consumed by the driver during runtime.
>>> I have no problem with providing precompiled binaries to linux-firmware,
>>> if that's what community wants.
>>>
>>> Regards,
>>> Czarek
>>>
>>>
>>
>> I think the guild [1] is too complicated for normal users to fix the problem.
>> Given it's not only the internal microphone being affected, it's no sound
>> devices being created at all so no audio functions can work after kernel 5.8.
>>
>> Is there any potential problem to built-in the "<any> with hda dsp" precompiled
>> binary in linux-firmware?
> 
> How do you distribute the SOF firmware? I'm going to include those binary
> topology files to the SOF firmware package for Fedora. Perhaps, you may follow
> this.
> 

Wouldn't it make more sense to distribute binaries along with confs from 
which they are build, which are already installed by alsa-topology package?
Similarly Ubuntu could use alsa-topology-conf package...



^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: No sound cards detected on Kabylake laptops after upgrade to kernel 5.8
  2021-03-11 10:40       ` Amadeusz Sławiński
@ 2021-03-11 14:10         ` Jaroslav Kysela
  0 siblings, 0 replies; 7+ messages in thread
From: Jaroslav Kysela @ 2021-03-11 14:10 UTC (permalink / raw)
  To: Amadeusz Sławiński, Chris Chiu, Cezary Rojewski
  Cc: pierre-louis.bossart, alsa-devel, yang.jie, Takashi Iwai,
	Linux Kernel, liam.r.girdwood, broonie

Dne 11. 03. 21 v 11:40 Amadeusz Sławiński napsal(a):
> On 3/11/2021 11:24 AM, Jaroslav Kysela wrote:
>> Dne 11. 03. 21 v 6:50 Chris Chiu napsal(a):
>>> On Tue, Mar 9, 2021 at 11:29 PM Cezary Rojewski
>>> <cezary.rojewski@intel.com> wrote:
>>>>
>>>> On 2021-03-09 1:19 PM, Chris Chiu wrote:
>>>>> Hi Guys,
>>>>>       We have received reports that on some Kabylake laptops (Acer Swift
>>>>> SF314-54/55 and Lenovo Yoga C930...etc), all sound cards no longer be
>>>>> detected after upgrade to kernel later than 5.8. These laptops have
>>>>> one thing in common, all of them have Realtek audio codec and connect
>>>>> the internal microphone to DMIC of the Intel SST controller either
>>>>> [8086:9d71] or [8086:9dc8]. Please refer to
>>>>> https://bugzilla.kernel.org/show_bug.cgi?id=201251#c246 and
>>>>> https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1915117.
>>>>>
>>>>>       From the dmesg from kernel 5.8, the sound related parts only show
>>>>> as follows but the expected snd_hda_codec_realtek and the snd_soc_skl
>>>>> are not even loaded then.
>>>>> [ 13.357495] snd_hda_intel 0000:00:1f.3: DSP detected with PCI
>>>>> class/subclass/prog-if info 0x040100
>>>>> [ 13.357500] snd_hda_intel 0000:00:1f.3: Digital mics found on
>>>>> Skylake+ platform, using SST driver
>>>>>
>>>>>       Building the kernel with the CONFIG_SND_SOC_INTEL_KBL removed can
>>>>> load the snd_hda_codec_realtek successfully and the pulseaudio and
>>>>> alsa-utils can detect the sound cards again. The result of bisecting
>>>>> between kernel 5.4 and 5.8 also get similar result, reverting the
>>>>> commit "ALSA: hda: Allow SST driver on SKL and KBL platforms with
>>>>> DMIC" can fix the issue. I tried to generate the required firmware for
>>>>> snd_soc_skl but it did not help. Please refer to what I did in
>>>>> https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1915117/comments/14
>>>>> and https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1915117/comments/18.
>>>>>
>>>>>       Since the skl_hda_dsp_generic-tplg.bin and dfw_sst.bin are not in
>>>>> the linux-firmware. The Intel SST support for Skylake family is not
>>>>> yet complete. Can we simply revert the "ALSA: hda: Allow SST driver on
>>>>> SKL and KBL platforms with DMIC" in the current stage and wait for SOF
>>>>> support for Skylake family? Or please suggest a better solution for
>>>>> this. Thanks
>>>>>
>>>>> Chris
>>>>>
>>>>
>>>> Hello Chris,
>>>>
>>>> Guide: "Linux: HDA+DMIC with skylake driver" [1] should help
>>>> understanding history behind the problem as well as fixing it.
>>>>
>>>> Upstream skylake driver - snd_soc_skl - is intended to support HDA DSP +
>>>> DMIC configuration via means of snd_soc_skl_hda_dsp machine board
>>>> driver. You _may_ switch to legacy HDAudio driver - snd_hda_intel -
>>>> losing DMIC support in the process. To remove any confusion - for
>>>> Skylake and Kabylake platforms, snd_soc_skl is your option.
>>>>
>>>> Now, due to above, I doubt any skylake-related topology has ever been
>>>> upstreamed to linux-firmware as a) most boards are I2S-based, these are
>>>> used by our clients which we support via separate channel b) hda
>>>> dsp+dmic support on linux for missing until early 2020.
>>>>
>>>> Topologies for most common skylake driver configurations:
>>>> - skl/kbl with i2s rt286
>>>> - apl/glk with i2s rt298
>>>> - <any> with hda dsp
>>>> can be found in alsa-topology-conf [2].
>>>>
>>>> Standard, official tool called 'alsatplg' is capable of compiling these
>>>> into binary form which, after being transferred to /lib/firmware/ may be
>>>> consumed by the driver during runtime.
>>>> I have no problem with providing precompiled binaries to linux-firmware,
>>>> if that's what community wants.
>>>>
>>>> Regards,
>>>> Czarek
>>>>
>>>>
>>>
>>> I think the guild [1] is too complicated for normal users to fix the problem.
>>> Given it's not only the internal microphone being affected, it's no sound
>>> devices being created at all so no audio functions can work after kernel 5.8.
>>>
>>> Is there any potential problem to built-in the "<any> with hda dsp" precompiled
>>> binary in linux-firmware?
>>
>> How do you distribute the SOF firmware? I'm going to include those binary
>> topology files to the SOF firmware package for Fedora. Perhaps, you may follow
>> this.
>>
> 
> Wouldn't it make more sense to distribute binaries along with confs from 
> which they are build, which are already installed by alsa-topology package?
> Similarly Ubuntu could use alsa-topology-conf package...

From the packaging perpective, it would be another package which should be
forcefully installed on x86_64 containing few files (and it's unclear if the
list will be extended in future). Also the .conf files are not required for
the operation. But it's just my suggestion, other distributions can choose a
different approach.

I just created Makefile [1] which may help with the packaging, because the
topology .conf -> fw .bin relation is _unclear_ for may of us for those SST
drivers. If you know more information (you can fill the rules for other
topology files), please, share it with us.

					Jaroslav

[1] https://github.com/alsa-project/alsa-topology-conf/blob/master/Makefile


-- 
Jaroslav Kysela <perex@perex.cz>
Linux Sound Maintainer; ALSA Project; Red Hat, Inc.

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2021-03-11 14:11 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-03-09 12:19 No sound cards detected on Kabylake laptops after upgrade to kernel 5.8 Chris Chiu
2021-03-09 15:29 ` Cezary Rojewski
2021-03-11  5:50   ` Chris Chiu
2021-03-11  7:58     ` Cezary Rojewski
2021-03-11 10:24     ` Jaroslav Kysela
2021-03-11 10:40       ` Amadeusz Sławiński
2021-03-11 14:10         ` Jaroslav Kysela

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).