]> code.delx.au - pulseaudio/commit
alsa: disable timer-based scheduling inside a VM
authorLennart Poettering <lennart@poettering.net>
Thu, 5 Nov 2009 02:23:08 +0000 (03:23 +0100)
committerLennart Poettering <lennart@poettering.net>
Thu, 5 Nov 2009 02:23:08 +0000 (03:23 +0100)
commit53b046d5c9593d848270e85017c2999a61256e0e
treebc60409ef2e9b6307f9858bf324f6d1766bf3d9d
parentc079ceeba00c77a93c613ecf4a3f2cb516db0753
alsa: disable timer-based scheduling inside a VM

In virtual machines sound card clocks and OS scheduling tend to become
unreliable, adding various 'uneven' latencies. The adaptive algorithm
that handles drop-outs does not handle it this well: in contrast to
drop-outs on real machines that are evenly distributed, small and can
easily be encountered via the adpative algorithms, drop-outs in VMs tend
to happen abruptly, and massively, which is not easy to counter.

This patch simply disables timer based scheduling in VMs reverting to
classic IO based scheduling. This should help make PA perform better in
VMs.

https://bugzilla.redhat.com/show_bug.cgi?id=532775
src/modules/alsa/alsa-sink.c
src/modules/alsa/alsa-source.c
src/modules/alsa/alsa-util.c
src/modules/alsa/alsa-util.h