All of lore.kernel.org
 help / color / mirror / Atom feed
From: GitHub issues - edited <github@alsa-project.org>
To: alsa-devel@alsa-project.org
Subject: Audio only working after stopping PulseAudio and setting the UCM - kblda7219max on the ChromeOS Kernel, 5.10.70
Date: Mon, 28 Mar 2022 00:28:16 +0200 (CEST)	[thread overview]
Message-ID: <20220327222816.76B24F80161@alsa1.perex.cz> (raw)
In-Reply-To: <1648420089770205975-webhooks-bot@alsa-project.org>

alsa-project/alsa-ucm-conf issue #142 was edited from MilkyDeveloper:

On my `kblda7219max` Chromebook (baseboard: NAMI), internal audio works properly when the following conditions are met:
* Kernel 5.10.70 (ChromeOS fork) is used (the latest ChromeOS kernel has some kind of topology-related kernel bug)
* FW is copied from the ChromeOS rootfs to Linux
* UCM is converted to UCM2
* Only ALSA is used

However, whenever I start PulseAudio (`pulseaudio -vvvv`), audio is disabled, going to a dummy output.

PulseAudio passes through probing for the UCM files but errors out in this particular spot:
```
I: [pulseaudio] (alsa-lib)pcm_hw.c: SNDRV_PCM_IOCTL_PREPARE failed (-22)
I: [pulseaudio] alsa-util.c: snd_pcm_hw_params failed: Invalid argument
D: [pulseaudio] alsa-util.c: Trying hw:kblda7219max,0 without SND_PCM_NO_AUTO_FORMAT ...
D: [pulseaudio] alsa-util.c: Managed to open hw:kblda7219max,0
D: [pulseaudio] alsa-util.c: Maximum hw buffer size is 21845 ms
I: [pulseaudio] (alsa-lib)pcm_hw.c: SNDRV_PCM_IOCTL_PREPARE failed (-22)
I: [pulseaudio] (alsa-lib)pcm_hw.c: SNDRV_PCM_IOCTL_PREPARE failed (-22)
I: [pulseaudio] (alsa-lib)pcm_hw.c: SNDRV_PCM_IOCTL_PREPARE failed (-22)
I: [pulseaudio] (alsa-lib)pcm_hw.c: SNDRV_PCM_IOCTL_PREPARE failed (-22)
```
which causes it to say:
```
E: [pulseaudio] module-alsa-card.c: Failed to find a working profile.
E: [pulseaudio] module.c: Failed to load module "module-alsa-card" (argument: "device_id="0" name="platform-kbl_da7219_mx98357a" card_name="alsa_card.platform-kbl_da7219_mx98357a" namereg_fail=false tsched=yes fixed_latency_range=no ignore_dB=no deferred_volume=yes use_ucm=yes avoid_resampling=no card_properties="module-udev-detect.discovered=1""): initialization failed.
```

My `dmesg` gets filled with:
```
Kbl Audio Port: ASoC: no backend DAIs enabled for Kbl Audio Port
Kbl Audio Port: ASoC: dpcm_fe_dai_prepare() failed (-22)
```

However, once I kill PulseAudio and run `alsaucm -c kblda7219max set _verb HiFi set _enadev Speaker`, audio begins working again (but this is in pure ALSA and PA apps are not compatible) and the `no backend DAIs enabled for Kbl Audio Port` is no longer logged to `dmesg`.

I think this is a UCM issue because the audio is working fine kernel-level and with ALSA, but PulseAudio seems to mess something up with the UCM and the UCM needs to be set again.

Huge thanks for any help!
[alsa-info.txt](https://github.com/alsa-project/alsa-ucm-conf/files/8355612/alsa-info.txt)
(My PulseAudio log is slightly different from the time I ran PulseAudio and got the PCM_IOCTL_PREPARE error)
[pulseaudio-log.txt](https://github.com/alsa-project/alsa-ucm-conf/files/8355613/pulseaudio-log.txt)
[HiFi.conf.txt](https://github.com/alsa-project/alsa-ucm-conf/files/8355631/HiFi.conf.txt)
[kblda7219max.conf.txt](https://github.com/alsa-project/alsa-ucm-conf/files/8355632/kblda7219max.conf.txt)

Issue URL     : https://github.com/alsa-project/alsa-ucm-conf/issues/142
Repository URL: https://github.com/alsa-project/alsa-ucm-conf

           reply	other threads:[~2022-03-27 22:29 UTC|newest]

Thread overview: expand[flat|nested]  mbox.gz  Atom feed
 [parent not found: <1648420089770205975-webhooks-bot@alsa-project.org>]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20220327222816.76B24F80161@alsa1.perex.cz \
    --to=github@alsa-project.org \
    --cc=alsa-devel@alsa-project.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.