Bug 15438

Summary: Unable to get audio output on qemux86-64
Product: [Yocto Project Subprojects] ADT Reporter: worryelectric
Component: adtAssignee: Unassigned <unassigned>
Status: NEW --- QA Contact:
Severity: normal    
Priority: Medium CC: paul, poky.adt.watcher, poky.watcher, randy.macleod, yoann.congal
Version: 5.1   
Target Milestone: 6.99   
Hardware: x86   
OS: x86_64   
Whiteboard:
OS type for building Yocto: --- Type of Regression: ---
Verified: Documentation change: No (bug/feature does not impact docs)

Description worryelectric 2024-03-10 22:07:22 UTC
I'm unable to get any audio output with `runqemu`. If I run an image as follows:

    runqemu qemux86-64 qemuparams="-m 2048" sdl gl serial slirp audio

And then in the guest run something that should output audio:

    aplay ~/wav/sample-15s.wav

Then no audio is played on the host. aplay runs as if it's outputting the 15 second audio file but no error and no actual audio.

However, if I use qemu parameters to output audio to a wav file then that does produce a file with the audio which I can playback:

    runqemu qemux86-64 qemuparams="-audiodev wav,id=id,path=blah -m 2048" sdl gl serial slirp audio

I don't know much about QEMU audio, but the fact that the wav file is created suggests that everything is good (the guest's drivers, the guest devices, etc.) but that the magic that sends the audio to the host device is broken. I've got no idea what to do to fix it despite much hacking around with the parameters in poky/meta/conf/machine/include/x86/qemuboot-x86.inc.

I've got the same issue on multiple machines and have no issue getting audio output on desktop VMs running on the distro's virt-manager with kvm. (Though that's not a fair comparison as that uses the spice driver.)

Is this a known issue?
Comment 1 Randy MacLeod 2024-03-14 14:35:42 UTC
We're not sure if this ever worked.
Comment 2 Randy MacLeod 2024-10-31 15:09:24 UTC
Bulk move of 5.1 bugs to 5.2. -- YP bug review (Randy)