Closed symdeb closed 1 year ago
Is it with PulseAudio or pipewire? And, is this reproducible on VM with the gadget driver, too?
The second question is basically to check whether the problem is device-specific or not. It might be that the device firmware is buggy and causes some issue when MIDI 2.0 is in use. I guess it's a generic problem, but still need to verify.
BTW, each open of a github issue and the edit of the content is notified / forwarded to alsa-devel mailing list, too. The ML is archived on lore.kernel.org, and it'll remain forever :) So, please be careful about editing. Your previous 26 times edits spewed 26 posts there.
Host uses Pipewire as provided with the Ubuntu 23.04 distro as default. no changes. This uses the pw-pulse (and pw-jack AFAIK) drop in replacements
It is re-produceable without actual MIDI 2 hardware or a VM It can be reproduced with a MIDI2 gadget as well.
Note snd_usb_audio is not removed because the external usb audio interface is used Does not occur with a MIDI1 gadget. This should exclude the hardware from the equation.
pactl info: Server String: /run/user/1000/pulse/native Library Protocol Version: 35 Server Protocol Version: 35 Is Local: yes Client Index: 124 Tile Size: 65472 User Name: user Host Name: H3 Server Name: PulseAudio (on PipeWire 0.3.65) Server Version: 15.0.0 Default Sample Specification: float32le 2ch 48000Hz Default Channel Map: front-left,front-right Default Sink: alsa_output.usb-Focusrite_Scarlett_18i20_USB-00.pro-output-0 Default Source: alsa_input.usb-Focusrite_Scarlett_18i20_USB-00.pro-input-0 Cookie: f33b:c78f
Thanks, it's clearer now.
The bug is in alsa-lib sequencer code, and it caused pipewire segfaulting. The seq->midi_version was incorrectly updated upon get_client_info for another client.
Glad the cause was found and fix implemented. https://github.com/alsa-project/alsa-lib/commit/dc1e683cc2d2aaed938f9459605d51d4a2cb7ba0
How to reproduce:
Note: A Focusrite 18i20 Gen 1 audio interface is used for audio playback and set in Pavucontrol as "pro Audio"
pavuctl screen goes blank and reinitializes itself. Unplug the device
Wait for about 30 seconds (this is important, sooner the error will appear) Repeat steps 2 and 4 . The error won't occur.
This is not unique to aplaymidi, other ALSA clients (aseqdump) may also cause this error. in almost all other applications there is no error, such a web browsers as playing videos in Youtube, the audio playback just stops. some applications , like browsers, can recover by readadjusting the timeline and restarting playback. Some can only recover after closing the application i.e mpv media player.