All of lore.kernel.org
 help / color / mirror / Atom feed
* Internal microphone does not work with 5.12 (Tiger Lake, X1 Nano)
@ 2021-05-27  9:50 Nico Schottelius
  2021-05-27  9:57 ` Jaroslav Kysela
  0 siblings, 1 reply; 9+ messages in thread
From: Nico Schottelius @ 2021-05-27  9:50 UTC (permalink / raw)
  To: alsa-devel


Hello,

it seems that the internal microphone does not work anymore with
5.12.6/5.12.7. I am somewhat sure it used to work within the 5.11.x
series and that sound did not work at all on 5.10.

I have uploaded the hardware information on

http://alsa-project.org/db/?f=f1a2b32db122695b2cf736db27cb6ed2fa8a9042

The microphone of a plugged in headset however *does* work.

Is this a known bug/regression and is there anything I can do to debug
it?

Best regards,

Nico


--
Sustainable and modern Infrastructures by ungleich.ch

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

* Re: Internal microphone does not work with 5.12 (Tiger Lake, X1 Nano)
  2021-05-27  9:50 Internal microphone does not work with 5.12 (Tiger Lake, X1 Nano) Nico Schottelius
@ 2021-05-27  9:57 ` Jaroslav Kysela
  2021-05-27 10:39   ` Nico Schottelius
  0 siblings, 1 reply; 9+ messages in thread
From: Jaroslav Kysela @ 2021-05-27  9:57 UTC (permalink / raw)
  To: Nico Schottelius; +Cc: ALSA development

On 27. 05. 21 11:50, Nico Schottelius wrote:
> 
> Hello,
> 
> it seems that the internal microphone does not work anymore with
> 5.12.6/5.12.7. I am somewhat sure it used to work within the 5.11.x
> series and that sound did not work at all on 5.10.
> 
> I have uploaded the hardware information on
> 
> http://alsa-project.org/db/?f=f1a2b32db122695b2cf736db27cb6ed2fa8a9042
> 
> The microphone of a plugged in headset however *does* work.
> 
> Is this a known bug/regression and is there anything I can do to debug
> it?

Could you check, if the Intel SOF driver is enabled in your kernel?

CONFIG_SND_SOC_SOF_TIGERLAKE

					Jaroslav

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

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

* Re: Internal microphone does not work with 5.12 (Tiger Lake, X1 Nano)
  2021-05-27  9:57 ` Jaroslav Kysela
@ 2021-05-27 10:39   ` Nico Schottelius
  2021-05-27 10:56     ` Kai Vehmanen
  0 siblings, 1 reply; 9+ messages in thread
From: Nico Schottelius @ 2021-05-27 10:39 UTC (permalink / raw)
  To: Jaroslav Kysela; +Cc: Nico Schottelius, alsa-devel



Jaroslav Kysela <perex@perex.cz> writes:

> On 27. 05. 21 11:50, Nico Schottelius wrote:
> Could you check, if the Intel SOF driver is enabled in your kernel?
>
> CONFIG_SND_SOC_SOF_TIGERLAKE

Just checked, it was disabled. I rebuilt 5.12.6, rebooted, but now the
sound card is gone (no device files in /dev/snd anymore), proably
failing due to:

[   55.713668] snd_hda_intel 0000:00:1f.3: DSP detected with PCI class/subclass/prog-if info 0x040380
[   55.713679] snd_hda_intel 0000:00:1f.3: Digital mics found on Skylake+ platform, using SOF driver
[   55.745863] sof-audio-pci-intel-tgl 0000:00:1f.3: DSP detected with PCI class/subclass/prog-if info 0x040380
[   55.745872] sof-audio-pci-intel-tgl 0000:00:1f.3: Digital mics found on Skylake+ platform, using SOF driver
[   55.746033] sof-audio-pci-intel-tgl 0000:00:1f.3: DSP detected with PCI class/subclass/prog-if 0x040380
[   55.748315] sof-audio-pci-intel-tgl 0000:00:1f.3: use msi interrupt mode
[   55.752671] sof-audio-pci-intel-tgl 0000:00:1f.3: warning: No matching ASoC machine driver found
[   55.752673] sof-audio-pci-intel-tgl 0000:00:1f.3: error: no matching ASoC machine driver found - aborting probe
[   55.752673] sof-audio-pci-intel-tgl 0000:00:1f.3: error: failed to get machine info -19
[   55.752764] sof-audio-pci-intel-tgl 0000:00:1f.3: error: failed to probe DSP hardware!

I have uploaded the full report on http://alsa-project.org/db/?f=d3c7ba9611b3c823709d7bce0df0f592b3471735

Nico

--
Sustainable and modern Infrastructures by ungleich.ch

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

* Re: Internal microphone does not work with 5.12 (Tiger Lake, X1 Nano)
  2021-05-27 10:39   ` Nico Schottelius
@ 2021-05-27 10:56     ` Kai Vehmanen
  2021-05-27 12:02       ` Nico Schottelius
  0 siblings, 1 reply; 9+ messages in thread
From: Kai Vehmanen @ 2021-05-27 10:56 UTC (permalink / raw)
  To: Nico Schottelius; +Cc: alsa-devel

Hi Nico,

On Thu, 27 May 2021, Nico Schottelius wrote:

> Just checked, it was disabled. I rebuilt 5.12.6, rebooted, but now the
> sound card is gone (no device files in /dev/snd anymore), proably
> failing due to:
> 
> [   55.713668] snd_hda_intel 0000:00:1f.3: DSP detected with PCI class/subclass/prog-if info 0x040380
> [   55.713679] snd_hda_intel 0000:00:1f.3: Digital mics found on Skylake+ platform, using SOF driver
> [   55.745863] sof-audio-pci-intel-tgl 0000:00:1f.3: DSP detected with PCI class/subclass/prog-if info 0x040380
> [   55.745872] sof-audio-pci-intel-tgl 0000:00:1f.3: Digital mics found on Skylake+ platform, using SOF driver
> [   55.746033] sof-audio-pci-intel-tgl 0000:00:1f.3: DSP detected with PCI class/subclass/prog-if 0x040380
> [   55.748315] sof-audio-pci-intel-tgl 0000:00:1f.3: use msi interrupt mode
> [   55.752671] sof-audio-pci-intel-tgl 0000:00:1f.3: warning: No matching ASoC machine driver found
> [   55.752673] sof-audio-pci-intel-tgl 0000:00:1f.3: error: no matching ASoC machine driver found - aborting probe
> [   55.752673] sof-audio-pci-intel-tgl 0000:00:1f.3: error: failed to get machine info -19
> [   55.752764] sof-audio-pci-intel-tgl 0000:00:1f.3: error: failed to probe DSP hardware!

it seems more kernel config options are missing. Distribution kernels 
typically enable all the machine drivers, but you are specifically missing
CONFIG_SND_SOC_INTEL_SKL_HDA_DSP_GENERIC_MACH=m

Distribution kernels are a good reference when building on your own, and 
we in SOF also maintain example kconfig settings for typical systems. 
Here's the bit for systems with DSP and HDA codecs:
https://github.com/thesofproject/kconfig/blob/master/hdaudio-codecs-defconfig

More info at:
https://github.com/thesofproject/kconfig/

Br, Kai


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

* Re: Internal microphone does not work with 5.12 (Tiger Lake, X1 Nano)
  2021-05-27 10:56     ` Kai Vehmanen
@ 2021-05-27 12:02       ` Nico Schottelius
  2021-05-27 13:43         ` Kai Vehmanen
  2021-05-27 13:55         ` Nico Schottelius
  0 siblings, 2 replies; 9+ messages in thread
From: Nico Schottelius @ 2021-05-27 12:02 UTC (permalink / raw)
  To: Kai Vehmanen; +Cc: Nico Schottelius, alsa-devel


Hey Kai,
Kai Vehmanen <kai.vehmanen@linux.intel.com> writes:

> Hi Nico,
>
> On Thu, 27 May 2021, Nico Schottelius wrote:
>
>> Just checked, it was disabled. I rebuilt 5.12.6, rebooted, but now the
>> sound card is gone (no device files in /dev/snd anymore), proably
>> failing due to:
>>
>> [   55.713668] snd_hda_intel 0000:00:1f.3: DSP detected with PCI class/subclass/prog-if info 0x040380
>> [   55.713679] snd_hda_intel 0000:00:1f.3: Digital mics found on Skylake+ platform, using SOF driver
>> [   55.745863] sof-audio-pci-intel-tgl 0000:00:1f.3: DSP detected with PCI class/subclass/prog-if info 0x040380
>> [   55.745872] sof-audio-pci-intel-tgl 0000:00:1f.3: Digital mics found on Skylake+ platform, using SOF driver
>> [   55.746033] sof-audio-pci-intel-tgl 0000:00:1f.3: DSP detected with PCI class/subclass/prog-if 0x040380
>> [   55.748315] sof-audio-pci-intel-tgl 0000:00:1f.3: use msi interrupt mode
>> [   55.752671] sof-audio-pci-intel-tgl 0000:00:1f.3: warning: No matching ASoC machine driver found
>> [   55.752673] sof-audio-pci-intel-tgl 0000:00:1f.3: error: no matching ASoC machine driver found - aborting probe
>> [   55.752673] sof-audio-pci-intel-tgl 0000:00:1f.3: error: failed to get machine info -19
>> [   55.752764] sof-audio-pci-intel-tgl 0000:00:1f.3: error: failed to probe DSP hardware!
>
> it seems more kernel config options are missing. Distribution kernels
> typically enable all the machine drivers, but you are specifically missing
> CONFIG_SND_SOC_INTEL_SKL_HDA_DSP_GENERIC_MACH=m

I've enabled this one and all machine types and indeed the card is being
recognised (report at
http://alsa-project.org/db/?f=5cbe7c293cbb80ab548b892cfc8b991476b0b2aa).
I checked permissions on /dev/snd, which looks good.

However, obs does not list the microphone at all and
chromium / jitsi shows the snd-hda-dsp mic, however does not let me
select it.

So with above options:

- playback works
- microphone does not work

> Distribution kernels are a good reference when building on your own, and
> we in SOF also maintain example kconfig settings for typical systems.
> Here's the bit for systems with DSP and HDA codecs:
> https://github.com/thesofproject/kconfig/blob/master/hdaudio-codecs-defconfig

I have used the .config from the linux-edge kernel from Alpine Linux as
a basis. The above configuration looks to be enabled in my .config as well.

Alpine's default config might include a bit less options than other
distros, I am currently in touch with the developers there for patching
it, as soon as I got the sound card properly working.

Best,

Nico

--
Sustainable and modern Infrastructures by ungleich.ch

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

* Re: Internal microphone does not work with 5.12 (Tiger Lake, X1 Nano)
  2021-05-27 12:02       ` Nico Schottelius
@ 2021-05-27 13:43         ` Kai Vehmanen
  2021-05-27 14:04           ` Nico Schottelius
  2021-05-27 13:55         ` Nico Schottelius
  1 sibling, 1 reply; 9+ messages in thread
From: Kai Vehmanen @ 2021-05-27 13:43 UTC (permalink / raw)
  To: Nico Schottelius; +Cc: alsa-devel

Hi Nico,

On Thu, 27 May 2021, Nico Schottelius wrote:

> > it seems more kernel config options are missing. Distribution kernels
> > typically enable all the machine drivers, but you are specifically missing
> > CONFIG_SND_SOC_INTEL_SKL_HDA_DSP_GENERIC_MACH=m
> 
> I've enabled this one and all machine types and indeed the card is being
> recognised (report at
> http://alsa-project.org/db/?f=5cbe7c293cbb80ab548b892cfc8b991476b0b2aa).
> I checked permissions on /dev/snd, which looks good.
> 
> However, obs does not list the microphone at all and
> chromium / jitsi shows the snd-hda-dsp mic, however does not let me
> select it.

ok, that's great so the driver appears to work now. You could try
to do simple arecord test in terminal:

arecord -fdat -vv -Dplugw:0,6 -c4 /dev/null

You should see vumeter activity from the built-in microphone.

If that works, this starts to go a bit outside the scope of this list, but 
it sounds something in Alpine's user-space integration is missing. In e.g. 
Fedora and Ubuntu, ALSA UCM file is provided for these platforms and the 
shipped versions of Pipewire/Pulseaudio can expose the devices correctly 
to apps. You can do a sanity test (of your hardware) by booting a recent 
live image of either distro.

Br, Kai

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

* Re: Internal microphone does not work with 5.12 (Tiger Lake, X1 Nano)
  2021-05-27 12:02       ` Nico Schottelius
  2021-05-27 13:43         ` Kai Vehmanen
@ 2021-05-27 13:55         ` Nico Schottelius
  1 sibling, 0 replies; 9+ messages in thread
From: Nico Schottelius @ 2021-05-27 13:55 UTC (permalink / raw)
  To: Nico Schottelius; +Cc: alsa-devel, Kai Vehmanen


I am not sure if this is related to the MIC not working:

[  160.122834] snd_hda_codec_realtek ehdaudio0D0: didn't find PCM for DAI Digital Codec DAI
[  160.122837] snd_hda_codec_realtek ehdaudio0D0: ASoC: error at snd_soc_dai_startup on Digital Codec DAI: -22
[  160.122839]  Digital Playback and Capture: ASoC: BE open failed -22
[  160.122841]  HDA Digital: ASoC: failed to start some BEs -22
[  160.122881] snd_hda_codec_realtek ehdaudio0D0: didn't find PCM for DAI Digital Codec DAI
[  160.122882] snd_hda_codec_realtek ehdaudio0D0: ASoC: error at snd_soc_dai_startup on Digital Codec DAI: -22
[  160.122883]  Digital Playback and Capture: ASoC: BE open failed -22
[  160.122884]  HDA Digital: ASoC: failed to start some BEs -22

I posted the full output on
http://alsa-project.org/db/?f=45fc657ecf37976734035202625a3c08841d7361

Firmware wise I downloaded the sof firmware from
https://github.com/thesofproject/sof-bin/, I am not sure if the "unknown
sof_ext_man header" message could be the problem:

[   48.431640] sof-audio-pci-intel-tgl 0000:00:1f.3: Firmware info: version 1:7:0-47d07
[   48.431642] sof-audio-pci-intel-tgl 0000:00:1f.3: Firmware: ABI 3:18:1 Kernel ABI 3:18:0
[   48.431643] sof-audio-pci-intel-tgl 0000:00:1f.3: unknown sof_ext_man header type 3 size 0x30
[   48.530671] sof-audio-pci-intel-tgl 0000:00:1f.3: Firmware info: version 1:7:0-47d07
[   48.530675] sof-audio-pci-intel-tgl 0000:00:1f.3: Firmware: ABI 3:18:1 Kernel ABI 3:18:0
[   48.534529] sof-audio-pci-intel-tgl 0000:00:1f.3: Topology: ABI 3:18:1 Kernel ABI 3:18:0

I also verified: the microphone of an external headset still works - so
basically the behaviour is the same as without the sof module.

Nico Schottelius <nico.schottelius@ungleich.ch> writes:

> Hey Kai,
> Kai Vehmanen <kai.vehmanen@linux.intel.com> writes:
>
>> Hi Nico,
>>
>> On Thu, 27 May 2021, Nico Schottelius wrote:
>>
>>> Just checked, it was disabled. I rebuilt 5.12.6, rebooted, but now the
>>> sound card is gone (no device files in /dev/snd anymore), proably
>>> failing due to:
>>>
>>> [   55.713668] snd_hda_intel 0000:00:1f.3: DSP detected with PCI class/subclass/prog-if info 0x040380
>>> [   55.713679] snd_hda_intel 0000:00:1f.3: Digital mics found on Skylake+ platform, using SOF driver
>>> [   55.745863] sof-audio-pci-intel-tgl 0000:00:1f.3: DSP detected with PCI class/subclass/prog-if info 0x040380
>>> [   55.745872] sof-audio-pci-intel-tgl 0000:00:1f.3: Digital mics found on Skylake+ platform, using SOF driver
>>> [   55.746033] sof-audio-pci-intel-tgl 0000:00:1f.3: DSP detected with PCI class/subclass/prog-if 0x040380
>>> [   55.748315] sof-audio-pci-intel-tgl 0000:00:1f.3: use msi interrupt mode
>>> [   55.752671] sof-audio-pci-intel-tgl 0000:00:1f.3: warning: No matching ASoC machine driver found
>>> [   55.752673] sof-audio-pci-intel-tgl 0000:00:1f.3: error: no matching ASoC machine driver found - aborting probe
>>> [   55.752673] sof-audio-pci-intel-tgl 0000:00:1f.3: error: failed to get machine info -19
>>> [   55.752764] sof-audio-pci-intel-tgl 0000:00:1f.3: error: failed to probe DSP hardware!
>>
>> it seems more kernel config options are missing. Distribution kernels
>> typically enable all the machine drivers, but you are specifically missing
>> CONFIG_SND_SOC_INTEL_SKL_HDA_DSP_GENERIC_MACH=m
>
> I've enabled this one and all machine types and indeed the card is being
> recognised (report at
> http://alsa-project.org/db/?f=5cbe7c293cbb80ab548b892cfc8b991476b0b2aa).
> I checked permissions on /dev/snd, which looks good.
>
> However, obs does not list the microphone at all and
> chromium / jitsi shows the snd-hda-dsp mic, however does not let me
> select it.
>
> So with above options:
>
> - playback works
> - microphone does not work
>
>> Distribution kernels are a good reference when building on your own, and
>> we in SOF also maintain example kconfig settings for typical systems.
>> Here's the bit for systems with DSP and HDA codecs:
>> https://github.com/thesofproject/kconfig/blob/master/hdaudio-codecs-defconfig
>
> I have used the .config from the linux-edge kernel from Alpine Linux as
> a basis. The above configuration looks to be enabled in my .config as well.
>
> Alpine's default config might include a bit less options than other
> distros, I am currently in touch with the developers there for patching
> it, as soon as I got the sound card properly working.
>
> Best,
>
> Nico


--
Sustainable and modern Infrastructures by ungleich.ch

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

* Re: Internal microphone does not work with 5.12 (Tiger Lake, X1 Nano)
  2021-05-27 13:43         ` Kai Vehmanen
@ 2021-05-27 14:04           ` Nico Schottelius
  2021-05-27 14:35             ` Pierre-Louis Bossart
  0 siblings, 1 reply; 9+ messages in thread
From: Nico Schottelius @ 2021-05-27 14:04 UTC (permalink / raw)
  To: Kai Vehmanen; +Cc: Nico Schottelius, alsa-devel


Hey Kai,
Kai Vehmanen <kai.vehmanen@linux.intel.com> writes:

> Hi Nico,
>
> On Thu, 27 May 2021, Nico Schottelius wrote:
>
>> > it seems more kernel config options are missing. Distribution kernels
>> > typically enable all the machine drivers, but you are specifically missing
>> > CONFIG_SND_SOC_INTEL_SKL_HDA_DSP_GENERIC_MACH=m
>>
>> I've enabled this one and all machine types and indeed the card is being
>> recognised (report at
>> http://alsa-project.org/db/?f=5cbe7c293cbb80ab548b892cfc8b991476b0b2aa).
>> I checked permissions on /dev/snd, which looks good.
>>
>> However, obs does not list the microphone at all and
>> chromium / jitsi shows the snd-hda-dsp mic, however does not let me
>> select it.
>
> ok, that's great so the driver appears to work now. You could try
> to do simple arecord test in terminal:
>
> arecord -fdat -vv -Dplugw:0,6 -c4 /dev/null

That does not work:

[15:55] nb3:~% arecord -fdat -vv -Dplugw:0,6 -c4 /dev/null
ALSA lib pcm.c:2660:(snd_pcm_open_noupdate) Unknown PCM plugw:0,6
arecord: main:830: audio open error: No such file or directory

However, recording with audacity produces to results:

- no sound recorded by default
- sound recorded when I plugin an external headset

And using arecord -fdat -vv -c4 /dev/null (without -Dplugw) I get
output, but the level is always 00% without the headset, ranges 02 ~ 90%
with the headset plugged in.

I was wondering if there's a hardware switch "broken"
for the detection of the headset and that's why the mic is muted
internally?


--
Sustainable and modern Infrastructures by ungleich.ch

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

* Re: Internal microphone does not work with 5.12 (Tiger Lake, X1 Nano)
  2021-05-27 14:04           ` Nico Schottelius
@ 2021-05-27 14:35             ` Pierre-Louis Bossart
  0 siblings, 0 replies; 9+ messages in thread
From: Pierre-Louis Bossart @ 2021-05-27 14:35 UTC (permalink / raw)
  To: Nico Schottelius, Kai Vehmanen; +Cc: alsa-devel




>> arecord -fdat -vv -Dplugw:0,6 -c4 /dev/null
> 
> That does not work:
> 
> [15:55] nb3:~% arecord -fdat -vv -Dplugw:0,6 -c4 /dev/null
> ALSA lib pcm.c:2660:(snd_pcm_open_noupdate) Unknown PCM plugw:0,6
> arecord: main:830: audio open error: No such file or directory

typo: you need to use plughw:0,6 or just hw:0,6

> 
> However, recording with audacity produces to results:
> 
> - no sound recorded by default
> - sound recorded when I plugin an external headset
> 
> And using arecord -fdat -vv -c4 /dev/null (without -Dplugw) I get
> output, but the level is always 00% without the headset, ranges 02 ~ 90%
> with the headset plugged in.
> 
> I was wondering if there's a hardware switch "broken"
> for the detection of the headset and that's why the mic is muted
> internally?

No, the DMIC has nothing to do with the headset, it's an independent 
interface.

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

end of thread, other threads:[~2021-05-27 14:37 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-05-27  9:50 Internal microphone does not work with 5.12 (Tiger Lake, X1 Nano) Nico Schottelius
2021-05-27  9:57 ` Jaroslav Kysela
2021-05-27 10:39   ` Nico Schottelius
2021-05-27 10:56     ` Kai Vehmanen
2021-05-27 12:02       ` Nico Schottelius
2021-05-27 13:43         ` Kai Vehmanen
2021-05-27 14:04           ` Nico Schottelius
2021-05-27 14:35             ` Pierre-Louis Bossart
2021-05-27 13:55         ` Nico Schottelius

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.