Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No audio from Starship/Matisse HD Audio Controller #129

Closed
ljmc2000 opened this issue Dec 12, 2021 · 33 comments
Closed

No audio from Starship/Matisse HD Audio Controller #129

ljmc2000 opened this issue Dec 12, 2021 · 33 comments

Comments

@ljmc2000
Copy link

ljmc2000 commented Dec 12, 2021

I have an AMD ryzen 3900X paired with a Gigabyte AX370-Gaming 5 motherboard. I use arch linux. Upon upgrading the package alsa-ucm-conf from version 1.2.6.1-1 to 1.2.6.2-2 and rebooting, my onboard audio stops working completely. Downgrading restores functionality after another reboot. In pavucontrol, for 1.2.6.1-1 there are many available profiles, but for 1.2.6.2-2 there is only one, which says unavailable. I also use pipewire rather than pulseaudio if that makes a difference

@perexg
Copy link
Member

perexg commented Dec 13, 2021

Please, show output from alsa-info.sh --no-upload (attach or post URL to gist / pastebin) and alsaucm -c hw:0 dump text (replace eventually 0 with the correct ALSA card number - aplay -l will give hints). Thank you.

@ljmc2000
Copy link
Author

alsaucm -c hw:0 dump text
ALSA lib main.c:1412:(snd_use_case_mgr_open) error: failed to import hw:0 use case configuration -2
alsaucm: error failed to open sound card hw:0: No such file or directory

as for alsa-info.sh
https://gist.github.com/SirFooOfBar/c5d5e4358da417902e97e37258b02677

@perexg
Copy link
Member

perexg commented Dec 13, 2021

Thanks, the right card is 2: alsaucm -c hw:2 dump text . Please, provide output from this command.

@ljmc2000
Copy link
Author

for i in 0 1 2 3; do alsaucm -c hw:$i dump text; done
ALSA lib main.c:1412:(snd_use_case_mgr_open) error: failed to import hw:0 use case configuration -2
alsaucm: error failed to open sound card hw:0: No such file or directory
ALSA lib main.c:1412:(snd_use_case_mgr_open) error: failed to import hw:1 use case configuration -2
alsaucm: error failed to open sound card hw:1: No such file or directory
ALSA lib main.c:1412:(snd_use_case_mgr_open) error: failed to import hw:2 use case configuration -2
alsaucm: error failed to open sound card hw:2: No such file or directory
ALSA lib main.c:1412:(snd_use_case_mgr_open) error: failed to import hw:3 use case configuration -2
alsaucm: error failed to open sound card hw:3: No such file or directory

@perexg
Copy link
Member

perexg commented Dec 14, 2021

Thanks. Please, output from strace alsaucm -c hw:2 dump text . Thank you.

@ljmc2000
Copy link
Author

ljmc2000 commented Dec 14, 2021

strace alsaucm -c hw:2 dump text

...

access("/usr/share/alsa/ucm2/conf.d/HDA-Intel/HDA ATI HDMI at 0xfcc20000 irq 75.conf", R_OK) = -1 ENOENT (No such file or directory)
access("/usr/share/alsa/ucm2/conf.d/HDA-Intel/HDA-Intel.conf", R_OK) = -1 ENOENT (No such file or directory)

@perexg
Copy link
Member

perexg commented Dec 14, 2021

The ucm2/conf.d/HDA-Intel/HDA-Intel.conf should be symlink to ../../HDA/HDA.conf :

$ ls -l ucm2/conf.d/HDA-Intel/HDA-Intel.conf 
... ucm2/conf.d/HDA-Intel/HDA-Intel.conf -> ../../HDA/HDA.conf

It looks like a bad packaging or so...
See https://github.com/alsa-project/alsa-ucm-conf/blob/master/ucm2/conf.d/HDA-Intel/HDA-Intel.conf

Which distribution are you using?

@ljmc2000
Copy link
Author

Arch linux, like I said in the initial comment

@perexg
Copy link
Member

perexg commented Dec 14, 2021

I overlooked this info, apologize. You may try unpack http://www.alsa-project.org/files/pub/lib/alsa-ucm-conf-1.2.6.2.tar.bz2 tar ball directly in /usr/share/alsa for a test. If things work, report the problem to your distribution.

tar xzjf alsa-ucm-conf-1.2.6.2.tar.bz2 -C /usr/share/alsa --strip-components=1 "*/ucm" "*/ucm2"

@ljmc2000
Copy link
Author

ljmc2000 commented Dec 14, 2021

alsaucm -c hw:3 dump text
Verb.HiFi {
        Comment Default
        Device.Line1 {
                Comment "Line Out"
                Values {
                        CaptureCTL "_ucm0001.hw:Generic"
                        JackControl "Line Out Front Jack"
                        PlaybackCTL "_ucm0001.hw:Generic"
                        PlaybackMixerElem Front
                        PlaybackPCM "_ucm0001.hw:Generic"
                        PlaybackPriority 200
                        TQ HiFi
                }
        }
        Device.Headphones {
                Comment Headphones
                Values {
                        CaptureCTL "_ucm0001.hw:Generic"
                        JackControl "Front Headphone Jack"
                        PlaybackCTL "_ucm0001.hw:Generic"
                        PlaybackMixerElem Headphone
                        PlaybackPCM "_ucm0001.hw:Generic,4"
                        PlaybackPriority 300
                        TQ HiFi
                }
        }
        Device.Line2 {
                Comment "Rear Line In"
                ConflictingDevices [
                        Mic2
                ]
                Values {
                        CaptureCTL "_ucm0001.hw:Generic"
                        CaptureMasterElem "Line Boost"
                        CaptureMixerElem Rear-Panel
                        CapturePCM "_ucm0001.hw:Generic"
                        CapturePriority 200
                        JackControl "Line Jack"
                        PlaybackCTL "_ucm0001.hw:Generic"
                        TQ HiFi
                }
        }
        Device.Mic2 {
                Comment "Rear Microphone"
                ConflictingDevices [
                        Line2
                ]
                Values {
                        CaptureCTL "_ucm0001.hw:Generic"
                        CaptureMasterElem "Rear Mic Boost"
                        CaptureMixerElem Rear-Panel
                        CapturePCM "_ucm0001.hw:Generic"
                        CapturePriority 300
                        JackControl "Rear Mic Jack"
                        JackHWMute Line2
                        PlaybackCTL "_ucm0001.hw:Generic"
                        TQ HiFi
                }
        }
        Device.Mic1 {
                Comment "Front Microphone"
                Values {
                        CaptureCTL "_ucm0001.hw:Generic"
                        CaptureMasterElem "Front Mic Boost"
                        CaptureMixerElem Front-Panel
                        CapturePCM "_ucm0001.hw:Generic,4"
                        CapturePriority 100
                        JackControl "Front Mic Jack"
                        PlaybackCTL "_ucm0001.hw:Generic"
                        TQ HiFi
                }
        }
}

Still no audio

@perexg
Copy link
Member

perexg commented Dec 14, 2021

Reboot or restart pulseaudio / pipewire? Do you see the audio devices there ?

@ljmc2000
Copy link
Author

The device is always there, and I only lose it after rebooting
In version 1.2.6.1-1 it has the profiles seen in this image: https://ibb.co/S3Qnrh2
In version 1.2.6.2-2 it has only one profile called "unavailable"

@perexg
Copy link
Member

perexg commented Dec 14, 2021

It seems that the jack detection is not working properly on your hardware - if you look to the alsa-info.sh you provided - all Jack controls (like 'Front Headphone Jack' are false). It seems like a driver bug. I think that you can select manually the profile even if it's unavailable (driver reports that nothing is inserted to the jack) in PA.

@ljmc2000
Copy link
Author

If it's a driver bug, why does it work with 1.2.6.1 but not 1.2.6.2? This is some sort of config package right? wheras when I hear driver I think kernel module. Or does that have some other meaning? And yes, the profile can be selected, but no sound comes out. Well that's not quite true. I can hear very faint radio static, though I have no idea what that implies

@perexg
Copy link
Member

perexg commented Dec 14, 2021

The PA fall back to the legacy device management in 1.2.6.1-1 for a reason . UCM is different, it should add the extra devices for your system (front panel - 'Headphones' and 'Mic1').

If you look to the UCM config dump, you can see all ALSA controls there:

  • PCM devices (PlaybackPCM, CapturePCM)
  • Mixer controls (PlaybackMixerElem, CaptureMixerElem)
  • Jack controls (JackControl)

You can check all paths using the ALSA commands like 'alsamixer', 'speaker-test', 'aplay', 'amixer -c /CARDNO/ controls' or so..

@perexg
Copy link
Member

perexg commented Dec 14, 2021

Do you use SPDIF output ?

@ljmc2000
Copy link
Author

I do not. I use rear line out.

@perexg
Copy link
Member

perexg commented Dec 14, 2021

Apologize again, 'Line Out Front Jack' is true, so the config bellow should be picked from PA:

        Device.Line1 {
                Comment "Line Out"
                Values {
                        CaptureCTL "_ucm0001.hw:Generic"
                        JackControl "Line Out Front Jack"
                        PlaybackCTL "_ucm0001.hw:Generic"
                        PlaybackMixerElem Front
                        PlaybackPCM "_ucm0001.hw:Generic"
                        PlaybackPriority 200
                        TQ HiFi
                }
        }

Could you show the PA log ? (please, only URL or attach it)

https://fedoraproject.org/wiki/How_to_debug_PulseAudio_problems

Does pasuspender -- speaker-test -D plughw:Generic command work on your system? If you, try to fiddle the mixer settings using alsamixer -c Generic command.

@ljmc2000
Copy link
Author

I use pipewire not pulseaudio

@perexg
Copy link
Member

perexg commented Dec 14, 2021

You can use speaker-test if you stop pipewire (just remove pasuspender -- prefix).

@ljmc2000
Copy link
Author

running speaker-test -D plughw:Generic:
very quiet crackling sounds. Nothing else

@perexg
Copy link
Member

perexg commented Dec 14, 2021

Ok, could you try the mixer settings (alsamixer -c Generic in the terminal - playback view) while the speaker-test is active to set the proper volume? The UCM config use Front control, but Master or/and PCM controls may change something, too.

@ljmc2000
Copy link
Author

https://ibb.co/gR7NJh9

@perexg
Copy link
Member

perexg commented Dec 14, 2021

And if you toggle mute for Headphone ? (Space key)

@perexg
Copy link
Member

perexg commented Dec 14, 2021

Also, you may test speaker-test -D plughw:Generic,4 command, but this device should be for the front jack.

@ljmc2000
Copy link
Author

As it turns out, toggling mute is the M key and space does nothing. However, unmuting did not make the audio start working. I heard that faint radio static again, but nothing usable

@perexg
Copy link
Member

perexg commented Dec 14, 2021

Yes, M is for playback, Space for capture. I am tired. Anyway, we can compare alsa-info.sh output from working / non-working case (speaker-test when pipewire works with the old alsa-lib version), if you can grab it. You're testing the driver directly now (without UCM), so I'm curious where's the problem.

@ljmc2000
Copy link
Author

Both a working and non working dump from alsa-info.sh were attached to the original gist, which I'm going to repost here. Happy bug hunting, remember to sleep at some point please. https://gist.github.com/SirFooOfBar/c5d5e4358da417902e97e37258b02677

@perexg
Copy link
Member

perexg commented Dec 15, 2021

It seems that the only difference is for the Front control:

@@ -3866,8 +3877,8 @@
 	control.2 {
 		iface MIXER
 		name 'Front Playback Switch'
-		value.0 false
-		value.1 false
+		value.0 true
+		value.1 true
 		comment {
 			access 'read write'
 			type BOOLEAN

@ljmc2000
Copy link
Author

Just upgraded to 1.2.8-1and the line out audio seems to be working so I'm gonna call this issue closed

@Lensters
Copy link

Lensters commented Nov 3, 2023

I'm having the same issue, but I can't find a version 1.2.8-1 to upgrade to???

@ljmc2000
Copy link
Author

ljmc2000 commented Nov 3, 2023

I'm having the same issue, but I can't find a version 1.2.8-1 to upgrade to???

What distro do you use? For archlinux, 1.2.8-1 is a very old version at this point and can be found here

If you use an apt distro like ubuntu, you may find it here

If rpm is your jam, this appears to be the equivalent fedora package

@Lensters
Copy link

Lensters commented Nov 3, 2023

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants