Audio PCI passthrough distorted

imrazor

Member
Nov 3, 2015
40
0
6
I've been experimenting with PCI/PCIe passthrough this week, and actually managed to get it working. However, the fly in the ointment has been audio. USB audio was horribly garbled. Passing through the host's onboard audio works a lot better, but I still get crackling and skips in the audio when playing Youtube videos. Curiously, audio in the one game I tried worked perfectly. The issue seems worse when there is a lot of network activity.

I've tried a couple of things to fix it. I enabled MSI interrupts on the onboard audio in the Windows VM, no change. I also tried the Red Hat VirtIO network driver, again no change.

I've also noticed some error messages in the host's dmesg output about the network card firmware being missing (tg3 driver), however the host seems to access the network w/o issue. I also passed the onboard audio through as a multi-function device; would it work better if I passed it through as a single function device?
 
Well I found a functional, if not perfect, answer to my problem. The biggest problem was the OS. I was trying to get audio working with Windows Server 2012 R2. Once I switched to Windows 10, things became easier. After switching, I still had to enable Message Server Interrupts to prevent an audio/visual sync problem. It still distorts a bit when there's really heavy I/O, but I can live with it.
 
The audio distortion with significant I/O is worse than I thought. So no one has any idea how to get decent sound out of KVM? Audio is fine when there's no network I/O, but the cracks start to show when streaming video or downloading in the background. It's not the hardware, because ESXi can handle simultaneous network, disk and audio I/O on the same hardware, though GPU passthrough is a bit slower.
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!