My mother board is ASUS ROS STRIX Z590-A Gaming WiFi that comes with a Realtek ALC4080 USB Audio chip, it does not work on Ubuntu 20.04 with 5.15 kernel. For headphone, I could get the sound from it only if it has been plugged in before booting, which means that I no long get any playback sound if I reseat the headphone while the system is running. Headphone mic does not work at all with either front panel or rear panel. BTW, headphone and mic can always be detected as shown in pavucontrol.
The front panel behaves a bit differently. Every time I re-plug the headphone in the 3.5mm jack on the front panel, it is detected as "Headphone (plugged in)" and the USB Audio profile is switched to "Analog Stereo Duplex" in pavucontrol. I could get the playback sound only by running aplay -D plughw:2,1 <path-to-audio-file>. but not from other applications, e.g. ffplay, that is configured to use pulseaudio as backend.
This is the output of inix -A:
Audio: Device-1: Intel driver: snd_hda_intel
Device-2: NVIDIA driver: snd_hda_intel
Device-3: ASUSTek USB Audio type: USB driver: hid-generic,snd-usb-audio,usbhid
Sound Server: ALSA v: k5.15.0-88-generic
But Device-1 is not accessible from alsamixer. The kernel log may imply the cause:
[ 1.700089] snd_hda_intel 0000:00:1f.3: enabling device (0000 -> 0002)
[ 1.702803] snd_hda_intel 0000:01:00.1: Disabling MSI
[ 1.702807] snd_hda_intel 0000:01:00.1: Handle vga_switcheroo audio client
[ 2.712442] snd_hda_intel 0000:00:1f.3: azx_get_response timeout, switching to polling mode: last cmd=0x000f0000
[ 3.724433] snd_hda_intel 0000:00:1f.3: No response from codec, disabling MSI: last cmd=0x000f0000
[ 4.732444] snd_hda_intel 0000:00:1f.3: Codec #0 probe error; disabling it...
[ 4.737657] snd_hda_codec_hdmi hdaudioC0D2: No i915 binding for Intel HDMI/DP codec
[ 4.738438] snd_hda_intel 0000:00:1f.3: Cannot probe codecs, giving u
Additional information:
$ aplay -l
**** List of PLAYBACK Hardware Devices ****
card 1: NVidia [HDA NVidia], device 3: HDMI 0 [HDMI 0]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 1: NVidia [HDA NVidia], device 7: HDMI 1 [HDMI 1]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 1: NVidia [HDA NVidia], device 8: HDMI 2 [HDMI 2]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 1: NVidia [HDA NVidia], device 9: HDMI 3 [HDMI 3]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 1: NVidia [HDA NVidia], device 10: HDMI 4 [HDMI 4]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 1: NVidia [HDA NVidia], device 11: HDMI 5 [HDMI 5]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 1: NVidia [HDA NVidia], device 12: HDMI 6 [HDMI 6]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 2: Audio [USB Audio], device 0: USB Audio [USB Audio]
Subdevices: 0/1
Subdevice #0: subdevice #0
card 2: Audio [USB Audio], device 1: USB Audio [USB Audio #1]
Subdevices: 0/1
Subdevice #0: subdevice #0
card 2: Audio [USB Audio], device 2: USB Audio [USB Audio #2]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 2: Audio [USB Audio], device 4: USB Audio [USB Audio #4]
Subdevices: 1/1
Subdevice #0: subdevice #0
I finally gave a try to the approach from realtek-alc4080-codec-front-jack-doesnt-work, adding the ALC4080 USB-Audio configuration, but got no luck. As long as the headphone get reseated, I no longer get any sound.
It seems that old version of alsa shipped by Ubuntu 20.04 is not able to handle ALC4080 correctly, but I have no idea how to easily get the new version of alsa while keeping the system is not broken.