[qubes-users] No sound in XPS9310

I installed qubes on a Dell XPS9310. I was using kernel 5.4.90 and sound was working, but wi-fi did not. So I upgraded to kernel 5.10.13 and now I have both wifi and sound not working :smiley:

It seems that the sound issues are due to a problem with driver sof-audio-pci.

In this thread: https://groups.google.com/g/qubes-users/c/Fa65-e8vqdM it turns out another user was having a similar problem with a dell 9700, which was apparently solved. Indeed in the thread it is said:

Audio works (with kernel 5.10 and attached kernel base-config patch + latest 1.6.1 sof-bin firmware https://github.com/thesofproject/sof-bin and alsa-ucm-config files. see https://blog.fts.scot/2020/07/04/dell-xps-2020-how-to-get-audio-working-on-linux/ for alsa ucm config ).

Unfortunately, I am not technically skilled enough to really understand the fix. Does it mean that I have to download kernel 5.10 (from were?), apply the patch provided in the thread (how?), include firmware and config files (how?) and then compile and install?
As you can see I don’t really have a specific question, and I’m more in search of a few clarifications to understand how to apply an apparently already available solution. :slight_smile:

Fab

Fabrizio Romano Genovese:

I installed qubes on a Dell XPS9310. I was using kernel 5.4.90 and sound
was working, but wi-fi did not. So I upgraded to kernel 5.10.13 and now I
have both wifi and sound not working :smiley:

It seems that the sound issues are due to a problem with driver
sof-audio-pci.
In this thread: https://groups.google.com/g/qubes-users/c/Fa65-e8vqdM it
turns out another user was having a similar problem with a dell 9700, which
was apparently solved. Indeed in the thread it is said:

Audio works (with kernel 5.10 and attached kernel base-config patch +
latest 1.6.1 sof-bin firmware GitHub - thesofproject/sof-bin: Firmware and topology binaries and
alsa-ucm-config files. see
Dell XPS 2020 – How to get audio working on Linux – mark g's blog
for alsa ucm config ).

Unfortunately, I am not technically skilled enough to really understand the
fix. Does it mean that I have to download kernel 5.10 (from were?), apply
the patch provided in the thread (how?), include firmware and config files
(how?) and then compile and install?
As you can see I don't really have a specific question, and I'm more in
search of a few clarifications to understand how to apply an apparently
already available solution. :slight_smile:

Per https://groups.google.com/g/qubes-users/c/Fa65-e8vqdM, are you running Qubes 4.1? That might be the first place to start. It implements audio in a separate VM, which might automagically resolve the issue or at least make for a more easily implemented solution. In that case, you'll want your VM's kernel to be the latest, so in dom0 do sudo qubes-dom0-update kernel-qubes-vm-latest (from memory). See if the audio driver loads in the audio VM. If not, it gets more complex.

You could convert it to an HVM which would allow you to recompile the kernel internal to the VM using standard Linux procedures- check documentation for the distribution you're using. If you didn't want to convert to HVM, I think you would have to build a kernel for dom0 first per [qubes-users] HOWTO: Compiling Kernels for dom0, then package for VM usage with Managing VM kernel | Qubes OS (note I haven't attempted this before).

Fabrizio Romano Genovese:

I installed qubes on a Dell XPS9310. I was using kernel 5.4.90 and sound
was working, but wi-fi did not. So I upgraded to kernel 5.10.13 and now I
have both wifi and sound not working :smiley:

It seems that the sound issues are due to a problem with driver
sof-audio-pci.
In this thread: https://groups.google.com/g/qubes-users/c/Fa65-e8vqdM it
turns out another user was having a similar problem with a dell 9700, which
was apparently solved. Indeed in the thread it is said:

Audio works (with kernel 5.10 and attached kernel base-config patch +
latest 1.6.1 sof-bin firmware GitHub - thesofproject/sof-bin: Firmware and topology binaries and
alsa-ucm-config files. see
Dell XPS 2020 – How to get audio working on Linux – mark g's blog
for alsa ucm config ).

Unfortunately, I am not technically skilled enough to really understand the
fix. Does it mean that I have to download kernel 5.10 (from were?), apply
the patch provided in the thread (how?), include firmware and config files
(how?) and then compile and install?
As you can see I don't really have a specific question, and I'm more in
search of a few clarifications to understand how to apply an apparently
already available solution. :slight_smile:

Per https://groups.google.com/g/qubes-users/c/Fa65-e8vqdM, are you running Qubes 4.1? That might be the first place to start. It implements audio in a separate VM, which might automagically resolve the issue or at least make for a more easily implemented solution. In that case, you'll want your VM's kernel to be the latest, so in dom0 do sudo qubes-dom0-update kernel-qubes-vm-latest (from memory). See if the audio driver loads in the audio VM. If not, it gets more complex.

You could convert it to an HVM which would allow you to recompile the kernel internal to the VM using standard Linux procedures- check documentation for the distribution you're using. If you didn't want to convert to HVM, I think you would have to build a kernel for dom0 first per [qubes-users] HOWTO: Compiling Kernels for dom0, then package for VM usage with Managing VM kernel | Qubes OS (note I haven't attempted this before).

I think your dell has different wifi and I think audio. The wifi driver for the xps 9310 is iwlwifi. Here is some firmware info: https://support.killernetworking.com/knowledge-base/killer-ax1650-in-debian-ubuntu-16-04/ and here is some qubes specific info on your wifi driver: https://github.com/QubesOS/qubes-issues/issues/5615

I think the audio is different too, as the xps 9700 needs the 5.10 kernel to work, but the base-config patch above does enable CONFIG_SND_SOC_SOF_INTEL_SOUNDWIRE which I think you need too.

To patch the kernel you must build it from source with qubes-builder https://www.qubes-os.org/doc/qubes-builder/. First configure it. Then change kernel to master branch in builer.conf. after the “make get-sources” is when you would patch with config-base in qubes-builder/qubes-src/linux-kernel.

fedora 33 5.10 kernel supports much more devices and audio works in the upstream fedora on both the 9700 and 9310 dells. I’ll see if I can get a patch into qubes the upstream kernel modules which fedora has added or at the minimum the SOF stuff in the patch. Then all our audio will just work with qubes.

Rama McIntosh:

fedora 33 5.10 kernel supports much more devices and audio works in the
upstream fedora on both the 9700 and 9310 dells. I'll see if I can get a
patch into qubes the upstream kernel modules which fedora has added or at
the minimum the SOF stuff in the patch. Then all our audio will just work
with qubes.

Thanks for jumping in, Rama. It's difficult to troubleshoot hardware without hands-on.

I think your dell has different wifi and I think audio. The wifi driver for the xps 9310 is iwlwifi. Here is some firmware info: https://support.killernetworking.com/knowledge-base/killer-ax1650-in-debian-ubuntu-16-04/ and here is some qubes specific info on your wifi driver: https://github.com/QubesOS/qubes-issues/issues/5615

Alas, no, I really have the AX500. The AX1650 is waay much more well behaved and it is the one that is usually shipped on XPS developer edition. Unfortunately XPS developer edition does not have a 32GB RAM option, which was absolutely needed for me, being Qubes unbelievably ram hungry. So I was forced to purchase the model with the Killer AX500 T_T

I think the audio is different too, as the xps 9700 needs the 5.10 kernel to work, but the base-config patch above does enable CONFIG_SND_SOC_SOF_INTEL_SOUNDWIRE which I think you need too.

To patch the kernel you must build it from source with qubes-builder https://www.qubes-os.org/doc/qubes-builder/. First configure it. Then change kernel to master branch in builer.conf. after the “make get-sources” is when you would patch with config-base in qubes-builder/qubes-src/linux-kernel.

The sad thing is that audio worked perfectly on kernel 5.4… I’ll try to give a look to this by the end of the week, when I’ll have a bit less work to do :slight_smile:

fedora 33 5.10 kernel supports much more devices and audio works in the upstream fedora on both the 9700 and 9310 dells. I’ll see if I can get a patch into qubes the upstream kernel modules which fedora has added or at the minimum the SOF stuff in the patch. Then all our audio will just work with qubes.

That would be a wonderful, wonderful thing. In the meantime I’ll try to learn how to compile my own kernels, my pc also tends to heat quite a lot and I suspect that a taylored kernel could make my overall experience better, correct me if I’m wrong… :slight_smile:

About awokd suggestions: I tried to install 4.1 but the installer doesn’t boot on my machine. Also, I’ve always been very unlucky with Qubes backups (traditionally I do them and they never work on restore), so I’d gladly avoid having to reinstall everything right now…

I think your dell has different wifi and I think audio. The wifi driver for the xps 9310 is iwlwifi. Here is some firmware info: https://support.killernetworking.com/knowledge-base/killer-ax1650-in-debian-ubuntu-16-04/ and here is some qubes specific info on your wifi driver: https://github.com/QubesOS/qubes-issues/issues/5615

Alas, no, I really have the AX500. The AX1650 is waay much more well behaved and it is the one that is usually shipped on XPS developer edition. Unfortunately XPS developer edition does not have a 32GB RAM option, which was absolutely needed for me, being Qubes unbelievably ram hungry. So I was forced to purchase the model with the Killer AX500 T_T

I think the audio is different too, as the xps 9700 needs the 5.10 kernel to work, but the base-config patch above does enable CONFIG_SND_SOC_SOF_INTEL_SOUNDWIRE which I think you need too.

To patch the kernel you must build it from source with qubes-builder https://www.qubes-os.org/doc/qubes-builder/. First configure it. Then change kernel to master branch in builer.conf. after the “make get-sources” is when you would patch with config-base in qubes-builder/qubes-src/linux-kernel.

The sad thing is that audio worked perfectly on kernel 5.4… I’ll try to give a look to this by the end of the week, when I’ll have a bit less work to do :slight_smile:

fedora 33 5.10 kernel supports much more devices and audio works in the upstream fedora on both the 9700 and 9310 dells. I’ll see if I can get a patch into qubes the upstream kernel modules which fedora has added or at the minimum the SOF stuff in the patch. Then all our audio will just work with qubes.

That would be a wonderful, wonderful thing. In the meantime I’ll try to learn how to compile my own kernels, my pc also tends to heat quite a lot and I suspect that a taylored kernel could make my overall experience better, correct me if I’m wrong… :slight_smile:

By any chance, does everyone know if there are any news about these audio issues? I’m updating the kernel to the latest version every week or so, but unfortunately sound is still not working :frowning:

Hello all,

I managed to finally install Qubes 4.1, but the audio problem is still not fixed. As awokd pointed out, in Qubes 4.1 I can define an audio-vm which, having fedora33, correctly recognizes my audio card.

I first tried the easy way: I created a sys-audio vm, and assigned the audio card to it. Unfortunately, the audio doesn’t really work smoothly: Playing youtube videos on sys-audio is very slow and the sound is continuously cackling.

Investigating things further, it seems that there is already some salt script I can use to create sys-audio. So I removed my sys-audio vm and I tried with

sudo qubesctl state.sls qvm.sys-audio
that lists two processes, one succeds and the other one fails. After this I have sys-audio again, but it is not used by default by any other vm. I tested with

qvm-prefs untrusted audiovm sysaudio

but audio still does not work. Youtube videos now do not really start. If I set audio back to dom0 and reboot the vm instead they do (but obviously I cannot hear anything given that dom0 has fedora32 which doesn’t like my card).

I feel like there’s something very simple that I am missing. Am I maybe issuing the wrong salt command to set up sys-audio?

Cheers,
Fab