audio from qemu guest suffers delay / pitch changes as of 5.x
Submitted by dim..@..il.com
Assigned to pul..@..op.org
Description
I have a Fedora 20 guest running inside a Fedora 20 host, both using pulseaudio. Up until recently, I could use audio apps (mostly Skype) from inside the guest without issues.
As of Fedora's rebasing of pulseaudio to 5.x, there seems to be some sort of timing skew and delay. This isn't limited to Skype; a slightly simpler test case:
Running "paplay /usr/share/sounds/alsa/Front_Left.wav" repeatedly, I observe:
-
In the host: no issues
-
In the guest:
The clip's voice pitch sounds slightly lower. This is consistent with running the command under time(1), where the just over 1.5s clip consistently takes 50-60ms longer in reported real time to play in the guest.
Running the paplay command repeatedly in the guest, starting each new invocation after the sound has stopped playing, there seems to be a "back up" of audio stream building up. After 5 or so runs, the sound doesn't start playing until after the command has finished executing in the terminal. Waiting some time after that seems to exhaust whatever buffer is being emptied, but the effect is back if I try another sequence of paplay commands.
The guest's configuration hasn't changed; as I mentioned above, this correlated perfectly with the 4.x -> 5.x upgrade in Fedora. More specifically, this started happening when only the host was upgraded to 5.x, with the guest still running PA 4.x.
The guest virtual hardware has always been:
00:04.0 Audio device: Intel Corporation 82801FB/FBM/FR/FW/FRW (ICH6 Family) High Definition Audio Controller (rev 01) 0 alsa_card.pci-0000_00_04.0 module-alsa-card.c
The host has two devices available, with the problem present no matter which one is used:
00:1b.0 Audio device: Intel Corporation 82801I (ICH9 Family) HD Audio Controller (rev 03) Bus 001 Device 010: ID 0d8c:0139 C-Media Electronics, Inc. 0 alsa_card.usb-C-Media_Electronics_Inc._DYNEX_USB_Audio_Device-00-Device module-alsa-card.c 1 alsa_card.pci-0000_00_1b.0 module-alsa-card.c