[libvirt PATCH 18/18] qemu: wire up support for backend specific audio settings

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Signed-off-by: Daniel P. Berrangé <berrange@xxxxxxxxxx>
---
 src/qemu/qemu_command.c                       | 164 +++++++++++++++++-
 src/qemu/qemu_validate.c                      |  34 ++++
 tests/qemuxml2argvdata/audio-alsa-best.args   |   2 +
 .../audio-alsa-best.x86_64-latest.args        |   2 +-
 tests/qemuxml2argvdata/audio-alsa-best.xml    |   4 +-
 .../audio-alsa-full.x86_64-latest.args        |   3 +-
 tests/qemuxml2argvdata/audio-alsa-full.xml    |   4 +-
 .../audio-coreaudio-best.args                 |   2 +
 .../audio-coreaudio-best.x86_64-latest.args   |   4 +-
 .../qemuxml2argvdata/audio-coreaudio-best.xml |   2 +-
 .../audio-coreaudio-full.x86_64-latest.args   |   3 +-
 .../qemuxml2argvdata/audio-coreaudio-full.xml |   4 +-
 tests/qemuxml2argvdata/audio-file-best.args   |   1 +
 .../audio-file-best.x86_64-latest.args        |   2 +-
 tests/qemuxml2argvdata/audio-file-best.xml    |   2 +-
 .../audio-file-full.x86_64-latest.args        |   3 +-
 tests/qemuxml2argvdata/audio-file-full.xml    |   2 +-
 .../audio-jack-full.x86_64-latest.args        |   4 +-
 tests/qemuxml2argvdata/audio-jack-full.xml    |   4 +-
 tests/qemuxml2argvdata/audio-oss-best.args    |   5 +
 .../audio-oss-best.x86_64-latest.args         |   3 +-
 tests/qemuxml2argvdata/audio-oss-best.xml     |   4 +-
 .../audio-oss-full.x86_64-latest.args         |   4 +-
 tests/qemuxml2argvdata/audio-oss-full.xml     |   6 +-
 .../audio-pulseaudio-best.args                |   4 +
 .../audio-pulseaudio-best.x86_64-latest.args  |   7 +-
 .../audio-pulseaudio-best.xml                 |   6 +-
 .../audio-pulseaudio-full.err                 |   2 +-
 .../audio-pulseaudio-full.x86_64-latest.args  |   4 +-
 .../audio-pulseaudio-full.xml                 |   6 +-
 tests/qemuxml2argvdata/audio-sdl-best.args    |   1 +
 .../audio-sdl-best.x86_64-latest.args         |   4 +-
 tests/qemuxml2argvdata/audio-sdl-best.xml     |   2 +-
 .../audio-sdl-full.x86_64-latest.args         |   3 +-
 tests/qemuxml2argvdata/audio-sdl-full.xml     |   4 +-
 35 files changed, 266 insertions(+), 45 deletions(-)

diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c
index 6e2294ba9a..a5a5c729b3 100644
--- a/src/qemu/qemu_command.c
+++ b/src/qemu/qemu_command.c
@@ -7615,6 +7615,40 @@ qemuBuildAudioCommonArg(virBufferPtr buf,
     }
 }
 
+static void
+qemuBuildAudioALSAArg(virBufferPtr buf,
+                      const char *prefix,
+                      virDomainAudioIOALSA *def)
+{
+    if (def->dev)
+        virBufferAsprintf(buf, ",%s.dev=%s", prefix, def->dev);
+}
+
+static void
+qemuBuildAudioCoreAudioArg(virBufferPtr buf,
+                           const char *prefix,
+                           virDomainAudioIOCoreAudio *def)
+{
+    if (def->bufferCount)
+        virBufferAsprintf(buf, ",%s.buffer-count=%u", prefix, def->bufferCount);
+}
+
+static void
+qemuBuildAudioJackArg(virBufferPtr buf,
+                      const char *prefix,
+                      virDomainAudioIOJack *def)
+{
+    if (def->serverName)
+        virBufferAsprintf(buf, ",%s.server-name=%s", prefix, def->serverName);
+    if (def->clientName)
+        virBufferAsprintf(buf, ",%s.client-name=%s", prefix, def->clientName);
+    if (def->connectPorts)
+        virBufferAsprintf(buf, ",%s.connect-ports=%s", prefix, def->connectPorts);
+    if (def->exactName)
+        virBufferAsprintf(buf, ",%s.exact-name=%s", prefix,
+                          virTristateSwitchTypeToString(def->exactName));
+}
+
 static void
 qemuBuildAudioOSSArg(virBufferPtr buf,
                      const char *prefix,
@@ -7622,6 +7656,33 @@ qemuBuildAudioOSSArg(virBufferPtr buf,
 {
     if (def->dev)
         virBufferAsprintf(buf, ",%s.dev=%s", prefix, def->dev);
+    if (def->bufferCount)
+        virBufferAsprintf(buf, ",%s.buffer-count=%u", prefix, def->bufferCount);
+    if (def->tryPoll)
+        virBufferAsprintf(buf, ",%s.try-poll=%s", prefix,
+                          virTristateSwitchTypeToString(def->tryPoll));
+}
+
+static void
+qemuBuildAudioPulseAudioArg(virBufferPtr buf,
+                            const char *prefix,
+                            virDomainAudioIOPulseAudio *def)
+{
+    if (def->name)
+        virBufferAsprintf(buf, ",%s.name=%s", prefix, def->name);
+    if (def->streamName)
+        virBufferAsprintf(buf, ",%s.stream-name=%s", prefix, def->streamName);
+    if (def->latency)
+        virBufferAsprintf(buf, ",%s.latency=%u", prefix, def->latency);
+}
+
+static void
+qemuBuildAudioSDLArg(virBufferPtr buf,
+                     const char *prefix,
+                     virDomainAudioIOSDL *def)
+{
+    if (def->bufferCount)
+        virBufferAsprintf(buf, ",%s.buffer-count=%u", prefix, def->bufferCount);
 }
 
 static int
@@ -7644,23 +7705,46 @@ qemuBuildAudioCommandLineArg(virCommandPtr cmd,
         break;
 
     case VIR_DOMAIN_AUDIO_TYPE_ALSA:
+        qemuBuildAudioALSAArg(&buf, "in", &def->backend.alsa.input);
+        qemuBuildAudioALSAArg(&buf, "out", &def->backend.alsa.output);
         break;
 
     case VIR_DOMAIN_AUDIO_TYPE_COREAUDIO:
+        qemuBuildAudioCoreAudioArg(&buf, "in", &def->backend.coreaudio.input);
+        qemuBuildAudioCoreAudioArg(&buf, "out", &def->backend.coreaudio.output);
         break;
 
     case VIR_DOMAIN_AUDIO_TYPE_JACK:
+        qemuBuildAudioJackArg(&buf, "in", &def->backend.jack.input);
+        qemuBuildAudioJackArg(&buf, "out", &def->backend.jack.output);
         break;
 
     case VIR_DOMAIN_AUDIO_TYPE_OSS:
         qemuBuildAudioOSSArg(&buf, "in", &def->backend.oss.input);
         qemuBuildAudioOSSArg(&buf, "out", &def->backend.oss.output);
+
+        if (def->backend.oss.tryMMap)
+            virBufferAsprintf(&buf, ",try-mmap=%s",
+                              virTristateSwitchTypeToString(def->backend.oss.tryMMap));
+        if (def->backend.oss.exclusive)
+            virBufferAsprintf(&buf, ",exclusive=%s",
+                              virTristateSwitchTypeToString(def->backend.oss.exclusive));
+        if (def->backend.oss.dspPolicySet)
+            virBufferAsprintf(&buf, ",dsp-policy=%d", def->backend.oss.dspPolicy);
         break;
 
     case VIR_DOMAIN_AUDIO_TYPE_PULSEAUDIO:
+        qemuBuildAudioPulseAudioArg(&buf, "in", &def->backend.pulseaudio.input);
+        qemuBuildAudioPulseAudioArg(&buf, "out", &def->backend.pulseaudio.output);
+
+        if (def->backend.pulseaudio.serverName)
+            virBufferAsprintf(&buf, ",server=%s", def->backend.pulseaudio.serverName);
         break;
 
     case VIR_DOMAIN_AUDIO_TYPE_SDL:
+        qemuBuildAudioSDLArg(&buf, "in", &def->backend.sdl.input);
+        qemuBuildAudioSDLArg(&buf, "out", &def->backend.sdl.output);
+
         if (def->backend.sdl.driver) {
             /*
              * Some SDL audio driver names are different on SDL 1.2
@@ -7679,6 +7763,8 @@ qemuBuildAudioCommandLineArg(virCommandPtr cmd,
         break;
 
     case VIR_DOMAIN_AUDIO_TYPE_FILE:
+        if (def->backend.file.path)
+            virBufferEscapeString(&buf, ",path=%s", def->backend.file.path);
         break;
 
     case VIR_DOMAIN_AUDIO_TYPE_LAST:
@@ -7731,16 +7817,63 @@ qemuBuildAudioCommonEnv(virCommandPtr cmd,
     }
 }
 
+static void
+qemuBuildAudioALSAEnv(virCommandPtr cmd,
+                      const char *prefix,
+                      virDomainAudioIOALSA *def)
+{
+    if (def->dev)
+        virCommandAddEnvFormat(cmd, "%sDEV=%s",
+                               prefix, def->dev);
+}
+
+static void
+qemuBuildAudioCoreAudioEnv(virCommandPtr cmd,
+                           virDomainAudioDefPtr def)
+{
+    if (def->backend.coreaudio.output.bufferCount)
+        virCommandAddEnvFormat(cmd, "QEMU_COREAUDIO_BUFFER_COUNT=%u",
+                               def->backend.coreaudio.output.bufferCount);
+    if (def->output.bufferLength)
+        virCommandAddEnvFormat(cmd, "QEMU_COREAUDIO_BUFFER_SIZE=%u",
+                               def->output.bufferLength);
+}
+
 static void
 qemuBuildAudioOSSEnv(virCommandPtr cmd,
                      const char *prefix,
+                     const char *prefix2,
                      virDomainAudioIOOSS *def)
 {
     if (def->dev)
         virCommandAddEnvFormat(cmd, "%sDEV=%s",
                                prefix, def->dev);
+    if (def->tryPoll)
+        virCommandAddEnvFormat(cmd, "%sTRY_POLL=%s", prefix2,
+                               virTristateSwitchTypeToString(def->tryPoll));
 }
 
+static void
+qemuBuildAudioPulseAudioEnv(virCommandPtr cmd,
+                            virDomainAudioDef *def)
+{
+    if (def->backend.pulseaudio.input.name)
+        virCommandAddEnvPair(cmd, "QEMU_PA_SOURCE",
+                             def->backend.pulseaudio.input.name);
+    if (def->backend.pulseaudio.output.name)
+        virCommandAddEnvPair(cmd, "QEMU_PA_SINK",
+                             def->backend.pulseaudio.output.name);
+
+    if (def->input.bufferLength)
+        virCommandAddEnvFormat(cmd, "QEMU_PA_SAMPLES=%u",
+                               def->input.bufferLength);
+
+    if (def->backend.pulseaudio.serverName)
+        virCommandAddEnvPair(cmd, "QEMU_PA_SERVER=%s",
+                             def->backend.pulseaudio.serverName);
+}
+
+
 static int
 qemuBuildAudioCommandLineEnv(virCommandPtr cmd,
                              virDomainDefPtr def)
@@ -7761,23 +7894,47 @@ qemuBuildAudioCommandLineEnv(virCommandPtr cmd,
         break;
 
     case VIR_DOMAIN_AUDIO_TYPE_ALSA:
+        qemuBuildAudioALSAEnv(cmd, "QEMU_AUDIO_ADC_", &audio->backend.alsa.input);
+        qemuBuildAudioALSAEnv(cmd, "QEMU_AUDIO_DAC_", &audio->backend.alsa.output);
         break;
 
     case VIR_DOMAIN_AUDIO_TYPE_COREAUDIO:
+        qemuBuildAudioCoreAudioEnv(cmd, audio);
         break;
 
     case VIR_DOMAIN_AUDIO_TYPE_JACK:
         break;
 
     case VIR_DOMAIN_AUDIO_TYPE_OSS:
-        qemuBuildAudioOSSEnv(cmd, "QEMU_OSS_ADC_", &audio->backend.oss.input);
-        qemuBuildAudioOSSEnv(cmd, "QEMU_OSS_DAC_", &audio->backend.oss.output);
+        qemuBuildAudioOSSEnv(cmd, "QEMU_OSS_ADC_", "QEMU_AUDIO_ADC_",
+                             &audio->backend.oss.input);
+        qemuBuildAudioOSSEnv(cmd, "QEMU_OSS_DAC_", "QEMU_AUDIO_DAC_",
+                             &audio->backend.oss.output);
+
+        if (audio->backend.oss.input.bufferCount)
+            virCommandAddEnvFormat(cmd, "QEMU_OSS_NFRAGS=%u",
+                                   audio->backend.oss.input.bufferCount);
+
+        if (audio->backend.oss.tryMMap)
+            virCommandAddEnvFormat(cmd, "QEMU_OSS_MMAP=%s",
+                                   virTristateSwitchTypeToString(audio->backend.oss.tryMMap));
+        if (audio->backend.oss.exclusive)
+            virCommandAddEnvFormat(cmd, "QEMU_OSS_EXCLUSIVE=%s",
+                                   virTristateSwitchTypeToString(audio->backend.oss.exclusive));
+        if (audio->backend.oss.dspPolicySet)
+            virCommandAddEnvFormat(cmd, "QEMU_OSS_POLICY=%d",
+                                   audio->backend.oss.dspPolicy);
         break;
 
     case VIR_DOMAIN_AUDIO_TYPE_PULSEAUDIO:
+        qemuBuildAudioPulseAudioEnv(cmd, audio);
         break;
 
     case VIR_DOMAIN_AUDIO_TYPE_SDL:
+        if (audio->output.bufferLength)
+            virCommandAddEnvFormat(cmd, "QEMU_SDL_SAMPLES=%u",
+                                   audio->output.bufferLength);
+
         if (audio->backend.sdl.driver) {
             /*
              * Some SDL audio driver names are different on SDL 1.2
@@ -7796,6 +7953,9 @@ qemuBuildAudioCommandLineEnv(virCommandPtr cmd,
         break;
 
     case VIR_DOMAIN_AUDIO_TYPE_FILE:
+        if (audio->backend.file.path)
+            virCommandAddEnvFormat(cmd, "QEMU_WAV_PATH=%s",
+                                   audio->backend.file.path);
         break;
 
     case VIR_DOMAIN_AUDIO_TYPE_LAST:
diff --git a/src/qemu/qemu_validate.c b/src/qemu/qemu_validate.c
index 5aaadcb82d..dc67d4c442 100644
--- a/src/qemu/qemu_validate.c
+++ b/src/qemu/qemu_validate.c
@@ -4189,6 +4189,11 @@ qemuValidateDomainDeviceDefAudio(virDomainAudioDefPtr audio,
                                _("setting audio buffer length is not supported with this QEMU"));
                 return -1;
             }
+            if (audio->backend.coreaudio.input.bufferCount) {
+                virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s",
+                               _("setting audio buffer count is not supported with this QEMU"));
+                return -1;
+            }
         }
         break;
 
@@ -4201,10 +4206,32 @@ qemuValidateDomainDeviceDefAudio(virDomainAudioDefPtr audio,
         break;
 
     case VIR_DOMAIN_AUDIO_TYPE_OSS:
+        if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_AUDIODEV)) {
+            if (audio->backend.oss.input.bufferCount !=
+                audio->backend.oss.output.bufferCount) {
+                virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s",
+                               _("setting audio buffer count is not supported with this QEMU"));
+                return -1;
+            }
+        }
         break;
 
     case VIR_DOMAIN_AUDIO_TYPE_PULSEAUDIO:
         if (!virQEMUCapsGet(qemuCaps, QEMU_CAPS_AUDIODEV)) {
+            if (audio->backend.pulseaudio.input.streamName ||
+                audio->backend.pulseaudio.output.streamName) {
+                virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s",
+                               _("setting audio stream name is not supported with this QEMU"));
+                return -1;
+            }
+
+            if (audio->backend.pulseaudio.input.latency ||
+                audio->backend.pulseaudio.output.latency) {
+                virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s",
+                               _("setting audio latency is not supported with this QEMU"));
+                return -1;
+            }
+
             if (audio->input.bufferLength != audio->output.bufferLength) {
                 virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s",
                                _("setting audio buffer length is not supported with this QEMU"));
@@ -4220,6 +4247,13 @@ qemuValidateDomainDeviceDefAudio(virDomainAudioDefPtr audio,
                                _("setting audio buffer length is not supported with this QEMU"));
                 return -1;
             }
+
+            if (audio->backend.sdl.input.bufferCount ||
+                audio->backend.sdl.output.bufferCount) {
+                virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s",
+                               _("setting audio buffer count is not supported with this QEMU"));
+                return -1;
+            }
         }
         break;
 
diff --git a/tests/qemuxml2argvdata/audio-alsa-best.args b/tests/qemuxml2argvdata/audio-alsa-best.args
index 4461fc670c..d6c73dfc8b 100644
--- a/tests/qemuxml2argvdata/audio-alsa-best.args
+++ b/tests/qemuxml2argvdata/audio-alsa-best.args
@@ -17,6 +17,8 @@ QEMU_AUDIO_DAC_VOICES=2 \
 QEMU_AUDIO_DAC_FIXED_FREQ=22050 \
 QEMU_AUDIO_DAC_FIXED_CHANNELS=4 \
 QEMU_AUDIO_DAC_FIXED_FMT=f32 \
+QEMU_AUDIO_ADC_DEV=/dev/dsp0 \
+QEMU_AUDIO_DAC_DEV=/dev/dsp1 \
 /usr/bin/qemu-system-i386 \
 -name QEMUGuest1 \
 -S \
diff --git a/tests/qemuxml2argvdata/audio-alsa-best.x86_64-latest.args b/tests/qemuxml2argvdata/audio-alsa-best.x86_64-latest.args
index 5f84dcca72..e9898c29de 100644
--- a/tests/qemuxml2argvdata/audio-alsa-best.x86_64-latest.args
+++ b/tests/qemuxml2argvdata/audio-alsa-best.x86_64-latest.args
@@ -36,7 +36,7 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \
 -audiodev id=audio1,driver=alsa,in.mixing-engine=on,in.fixed-settings=on,\
 in.voices=1,in.frequency=44100,in.channels=2,in.format=s16,\
 out.mixing-engine=on,out.fixed-settings=on,out.voices=2,out.frequency=22050,\
-out.channels=4,out.format=f32 \
+out.channels=4,out.format=f32,in.dev=/dev/dsp0,out.dev=/dev/dsp1 \
 -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\
 resourcecontrol=deny \
 -msg timestamp=on
diff --git a/tests/qemuxml2argvdata/audio-alsa-best.xml b/tests/qemuxml2argvdata/audio-alsa-best.xml
index cefcc47027..1a6d5f4d9f 100644
--- a/tests/qemuxml2argvdata/audio-alsa-best.xml
+++ b/tests/qemuxml2argvdata/audio-alsa-best.xml
@@ -31,10 +31,10 @@
     <input type='mouse' bus='ps2'/>
     <input type='keyboard' bus='ps2'/>
     <audio id='1' type='alsa'>
-      <input mixingEngine='yes' fixedSettings='yes' voices='1'>
+      <input mixingEngine='yes' fixedSettings='yes' voices='1' dev='/dev/dsp0'>
         <settings frequency='44100' channels='2' format='s16'/>
       </input>
-      <output mixingEngine='yes' fixedSettings='yes' voices='2'>
+      <output mixingEngine='yes' fixedSettings='yes' voices='2' dev='/dev/dsp1'>
         <settings frequency='22050' channels='4' format='f32'/>
       </output>
     </audio>
diff --git a/tests/qemuxml2argvdata/audio-alsa-full.x86_64-latest.args b/tests/qemuxml2argvdata/audio-alsa-full.x86_64-latest.args
index 6ade7ef069..3c1b5ba6a5 100644
--- a/tests/qemuxml2argvdata/audio-alsa-full.x86_64-latest.args
+++ b/tests/qemuxml2argvdata/audio-alsa-full.x86_64-latest.args
@@ -36,7 +36,8 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \
 -audiodev id=audio1,driver=alsa,in.mixing-engine=on,in.fixed-settings=on,\
 in.voices=1,in.buffer-length=100,in.frequency=44100,in.channels=2,\
 in.format=s16,out.mixing-engine=on,out.fixed-settings=on,out.voices=2,\
-out.buffer-length=200,out.frequency=22050,out.channels=4,out.format=f32 \
+out.buffer-length=200,out.frequency=22050,out.channels=4,out.format=f32,\
+in.dev=/dev/dsp0,out.dev=/dev/dsp1 \
 -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\
 resourcecontrol=deny \
 -msg timestamp=on
diff --git a/tests/qemuxml2argvdata/audio-alsa-full.xml b/tests/qemuxml2argvdata/audio-alsa-full.xml
index 2cd488a3a5..634b41a0f0 100644
--- a/tests/qemuxml2argvdata/audio-alsa-full.xml
+++ b/tests/qemuxml2argvdata/audio-alsa-full.xml
@@ -31,10 +31,10 @@
     <input type='mouse' bus='ps2'/>
     <input type='keyboard' bus='ps2'/>
     <audio id='1' type='alsa'>
-      <input mixingEngine='yes' fixedSettings='yes' voices='1' bufferLength='100'>
+      <input mixingEngine='yes' fixedSettings='yes' voices='1' bufferLength='100' dev='/dev/dsp0'>
         <settings frequency='44100' channels='2' format='s16'/>
       </input>
-      <output mixingEngine='yes' fixedSettings='yes' voices='2' bufferLength='200'>
+      <output mixingEngine='yes' fixedSettings='yes' voices='2' bufferLength='200' dev='/dev/dsp1'>
         <settings frequency='22050' channels='4' format='f32'/>
       </output>
     </audio>
diff --git a/tests/qemuxml2argvdata/audio-coreaudio-best.args b/tests/qemuxml2argvdata/audio-coreaudio-best.args
index f8250df5cb..cc8be459f6 100644
--- a/tests/qemuxml2argvdata/audio-coreaudio-best.args
+++ b/tests/qemuxml2argvdata/audio-coreaudio-best.args
@@ -17,6 +17,8 @@ QEMU_AUDIO_DAC_VOICES=2 \
 QEMU_AUDIO_DAC_FIXED_FREQ=22050 \
 QEMU_AUDIO_DAC_FIXED_CHANNELS=4 \
 QEMU_AUDIO_DAC_FIXED_FMT=f32 \
+QEMU_COREAUDIO_BUFFER_COUNT=42 \
+QEMU_COREAUDIO_BUFFER_SIZE=200 \
 /usr/bin/qemu-system-i386 \
 -name QEMUGuest1 \
 -S \
diff --git a/tests/qemuxml2argvdata/audio-coreaudio-best.x86_64-latest.args b/tests/qemuxml2argvdata/audio-coreaudio-best.x86_64-latest.args
index 93166f27de..273655840a 100644
--- a/tests/qemuxml2argvdata/audio-coreaudio-best.x86_64-latest.args
+++ b/tests/qemuxml2argvdata/audio-coreaudio-best.x86_64-latest.args
@@ -35,8 +35,8 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \
 -device ide-cd,bus=ide.1,unit=0,drive=libvirt-1-format,id=ide0-1-0,bootindex=1 \
 -audiodev id=audio1,driver=coreaudio,in.mixing-engine=on,in.fixed-settings=on,\
 in.voices=1,in.frequency=44100,in.channels=2,in.format=s16,\
-out.mixing-engine=on,out.fixed-settings=on,out.voices=2,out.frequency=22050,\
-out.channels=4,out.format=f32 \
+out.mixing-engine=on,out.fixed-settings=on,out.voices=2,out.buffer-length=200,\
+out.frequency=22050,out.channels=4,out.format=f32,out.buffer-count=42 \
 -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\
 resourcecontrol=deny \
 -msg timestamp=on
diff --git a/tests/qemuxml2argvdata/audio-coreaudio-best.xml b/tests/qemuxml2argvdata/audio-coreaudio-best.xml
index 8a79404fde..66c52bb24c 100644
--- a/tests/qemuxml2argvdata/audio-coreaudio-best.xml
+++ b/tests/qemuxml2argvdata/audio-coreaudio-best.xml
@@ -34,7 +34,7 @@
       <input mixingEngine='yes' fixedSettings='yes' voices='1'>
         <settings frequency='44100' channels='2' format='s16'/>
       </input>
-      <output mixingEngine='yes' fixedSettings='yes' voices='2'>
+      <output mixingEngine='yes' fixedSettings='yes' voices='2' bufferLength='200' bufferCount='42'>
         <settings frequency='22050' channels='4' format='f32'/>
       </output>
     </audio>
diff --git a/tests/qemuxml2argvdata/audio-coreaudio-full.x86_64-latest.args b/tests/qemuxml2argvdata/audio-coreaudio-full.x86_64-latest.args
index bc6c9e9241..2e8f7b6231 100644
--- a/tests/qemuxml2argvdata/audio-coreaudio-full.x86_64-latest.args
+++ b/tests/qemuxml2argvdata/audio-coreaudio-full.x86_64-latest.args
@@ -36,7 +36,8 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \
 -audiodev id=audio1,driver=coreaudio,in.mixing-engine=on,in.fixed-settings=on,\
 in.voices=1,in.buffer-length=100,in.frequency=44100,in.channels=2,\
 in.format=s16,out.mixing-engine=on,out.fixed-settings=on,out.voices=2,\
-out.buffer-length=200,out.frequency=22050,out.channels=4,out.format=f32 \
+out.buffer-length=200,out.frequency=22050,out.channels=4,out.format=f32,\
+in.buffer-count=50,out.buffer-count=42 \
 -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\
 resourcecontrol=deny \
 -msg timestamp=on
diff --git a/tests/qemuxml2argvdata/audio-coreaudio-full.xml b/tests/qemuxml2argvdata/audio-coreaudio-full.xml
index 671497986e..a46db6936b 100644
--- a/tests/qemuxml2argvdata/audio-coreaudio-full.xml
+++ b/tests/qemuxml2argvdata/audio-coreaudio-full.xml
@@ -31,10 +31,10 @@
     <input type='mouse' bus='ps2'/>
     <input type='keyboard' bus='ps2'/>
     <audio id='1' type='coreaudio'>
-      <input mixingEngine='yes' fixedSettings='yes' voices='1' bufferLength='100'>
+      <input mixingEngine='yes' fixedSettings='yes' voices='1' bufferLength='100' bufferCount='50'>
         <settings frequency='44100' channels='2' format='s16'/>
       </input>
-      <output mixingEngine='yes' fixedSettings='yes' voices='2' bufferLength='200'>
+      <output mixingEngine='yes' fixedSettings='yes' voices='2' bufferLength='200' bufferCount='42'>
         <settings frequency='22050' channels='4' format='f32'/>
       </output>
     </audio>
diff --git a/tests/qemuxml2argvdata/audio-file-best.args b/tests/qemuxml2argvdata/audio-file-best.args
index bd73a5b26f..22f5730c80 100644
--- a/tests/qemuxml2argvdata/audio-file-best.args
+++ b/tests/qemuxml2argvdata/audio-file-best.args
@@ -17,6 +17,7 @@ QEMU_AUDIO_DAC_VOICES=2 \
 QEMU_AUDIO_DAC_FIXED_FREQ=22050 \
 QEMU_AUDIO_DAC_FIXED_CHANNELS=4 \
 QEMU_AUDIO_DAC_FIXED_FMT=f32 \
+QEMU_WAV_PATH=audio.wav \
 /usr/bin/qemu-system-i386 \
 -name QEMUGuest1 \
 -S \
diff --git a/tests/qemuxml2argvdata/audio-file-best.x86_64-latest.args b/tests/qemuxml2argvdata/audio-file-best.x86_64-latest.args
index 546e4debe8..ff9248f002 100644
--- a/tests/qemuxml2argvdata/audio-file-best.x86_64-latest.args
+++ b/tests/qemuxml2argvdata/audio-file-best.x86_64-latest.args
@@ -36,7 +36,7 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \
 -audiodev id=audio1,driver=wav,in.mixing-engine=on,in.fixed-settings=on,\
 in.voices=1,in.frequency=44100,in.channels=2,in.format=s16,\
 out.mixing-engine=on,out.fixed-settings=on,out.voices=2,out.frequency=22050,\
-out.channels=4,out.format=f32 \
+out.channels=4,out.format=f32,path=audio.wav \
 -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\
 resourcecontrol=deny \
 -msg timestamp=on
diff --git a/tests/qemuxml2argvdata/audio-file-best.xml b/tests/qemuxml2argvdata/audio-file-best.xml
index 0617dbbc0b..3bd02c3f37 100644
--- a/tests/qemuxml2argvdata/audio-file-best.xml
+++ b/tests/qemuxml2argvdata/audio-file-best.xml
@@ -30,7 +30,7 @@
     <controller type='pci' index='0' model='pci-root'/>
     <input type='mouse' bus='ps2'/>
     <input type='keyboard' bus='ps2'/>
-    <audio id='1' type='file'>
+    <audio id='1' type='file' path='audio.wav'>
       <input mixingEngine='yes' fixedSettings='yes' voices='1'>
         <settings frequency='44100' channels='2' format='s16'/>
       </input>
diff --git a/tests/qemuxml2argvdata/audio-file-full.x86_64-latest.args b/tests/qemuxml2argvdata/audio-file-full.x86_64-latest.args
index 1f1f05b39c..e24d072298 100644
--- a/tests/qemuxml2argvdata/audio-file-full.x86_64-latest.args
+++ b/tests/qemuxml2argvdata/audio-file-full.x86_64-latest.args
@@ -36,7 +36,8 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \
 -audiodev id=audio1,driver=wav,in.mixing-engine=on,in.fixed-settings=on,\
 in.voices=1,in.buffer-length=100,in.frequency=44100,in.channels=2,\
 in.format=s16,out.mixing-engine=on,out.fixed-settings=on,out.voices=2,\
-out.buffer-length=200,out.frequency=22050,out.channels=4,out.format=f32 \
+out.buffer-length=200,out.frequency=22050,out.channels=4,out.format=f32,\
+path=audio.wav \
 -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\
 resourcecontrol=deny \
 -msg timestamp=on
diff --git a/tests/qemuxml2argvdata/audio-file-full.xml b/tests/qemuxml2argvdata/audio-file-full.xml
index c695a1715e..f88fe42b11 100644
--- a/tests/qemuxml2argvdata/audio-file-full.xml
+++ b/tests/qemuxml2argvdata/audio-file-full.xml
@@ -30,7 +30,7 @@
     <controller type='pci' index='0' model='pci-root'/>
     <input type='mouse' bus='ps2'/>
     <input type='keyboard' bus='ps2'/>
-    <audio id='1' type='file'>
+    <audio id='1' type='file' path='audio.wav'>
       <input mixingEngine='yes' fixedSettings='yes' voices='1' bufferLength='100'>
         <settings frequency='44100' channels='2' format='s16'/>
       </input>
diff --git a/tests/qemuxml2argvdata/audio-jack-full.x86_64-latest.args b/tests/qemuxml2argvdata/audio-jack-full.x86_64-latest.args
index 96856cd3d5..cb17a25c7e 100644
--- a/tests/qemuxml2argvdata/audio-jack-full.x86_64-latest.args
+++ b/tests/qemuxml2argvdata/audio-jack-full.x86_64-latest.args
@@ -36,7 +36,9 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \
 -audiodev id=audio1,driver=jack,in.mixing-engine=on,in.fixed-settings=on,\
 in.voices=1,in.buffer-length=100,in.frequency=44100,in.channels=2,\
 in.format=s16,out.mixing-engine=on,out.fixed-settings=on,out.voices=2,\
-out.buffer-length=200,out.frequency=22050,out.channels=4,out.format=f32 \
+out.buffer-length=200,out.frequency=22050,out.channels=4,out.format=f32,\
+in.server-name=fish,in.client-name=food,in.connect-ports=yum,\
+out.server-name=fish,out.client-name=food,out.connect-ports=yum \
 -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\
 resourcecontrol=deny \
 -msg timestamp=on
diff --git a/tests/qemuxml2argvdata/audio-jack-full.xml b/tests/qemuxml2argvdata/audio-jack-full.xml
index 129bf509a0..92351078a7 100644
--- a/tests/qemuxml2argvdata/audio-jack-full.xml
+++ b/tests/qemuxml2argvdata/audio-jack-full.xml
@@ -31,10 +31,10 @@
     <input type='mouse' bus='ps2'/>
     <input type='keyboard' bus='ps2'/>
     <audio id='1' type='jack'>
-      <input mixingEngine='yes' fixedSettings='yes' voices='1' bufferLength='100'>
+      <input mixingEngine='yes' fixedSettings='yes' voices='1' bufferLength='100' serverName='fish' clientName='food' connectPorts='yum'>
         <settings frequency='44100' channels='2' format='s16'/>
       </input>
-      <output mixingEngine='yes' fixedSettings='yes' voices='2' bufferLength='200'>
+      <output mixingEngine='yes' fixedSettings='yes' voices='2' bufferLength='200' serverName='fish' clientName='food' connectPorts='yum'>
         <settings frequency='22050' channels='4' format='f32'/>
       </output>
     </audio>
diff --git a/tests/qemuxml2argvdata/audio-oss-best.args b/tests/qemuxml2argvdata/audio-oss-best.args
index 054222992f..32a9c6f654 100644
--- a/tests/qemuxml2argvdata/audio-oss-best.args
+++ b/tests/qemuxml2argvdata/audio-oss-best.args
@@ -17,6 +17,11 @@ QEMU_AUDIO_DAC_VOICES=2 \
 QEMU_AUDIO_DAC_FIXED_FREQ=22050 \
 QEMU_AUDIO_DAC_FIXED_CHANNELS=4 \
 QEMU_AUDIO_DAC_FIXED_FMT=f32 \
+QEMU_OSS_ADC_DEV=/dev/dsp0 \
+QEMU_AUDIO_ADC_TRY_POLL=on \
+QEMU_OSS_DAC_DEV=/dev/dsp1 \
+QEMU_AUDIO_DAC_TRY_POLL=off \
+QEMU_OSS_NFRAGS=30 \
 /usr/bin/qemu-system-i386 \
 -name QEMUGuest1 \
 -S \
diff --git a/tests/qemuxml2argvdata/audio-oss-best.x86_64-latest.args b/tests/qemuxml2argvdata/audio-oss-best.x86_64-latest.args
index 3cff02e1ba..41fda4fb73 100644
--- a/tests/qemuxml2argvdata/audio-oss-best.x86_64-latest.args
+++ b/tests/qemuxml2argvdata/audio-oss-best.x86_64-latest.args
@@ -36,7 +36,8 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \
 -audiodev id=audio1,driver=oss,in.mixing-engine=on,in.fixed-settings=on,\
 in.voices=1,in.frequency=44100,in.channels=2,in.format=s16,\
 out.mixing-engine=on,out.fixed-settings=on,out.voices=2,out.frequency=22050,\
-out.channels=4,out.format=f32 \
+out.channels=4,out.format=f32,in.dev=/dev/dsp0,in.buffer-count=30,\
+in.try-poll=on,out.dev=/dev/dsp1,out.buffer-count=30,out.try-poll=off \
 -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\
 resourcecontrol=deny \
 -msg timestamp=on
diff --git a/tests/qemuxml2argvdata/audio-oss-best.xml b/tests/qemuxml2argvdata/audio-oss-best.xml
index 6904bcc93b..0561724dbe 100644
--- a/tests/qemuxml2argvdata/audio-oss-best.xml
+++ b/tests/qemuxml2argvdata/audio-oss-best.xml
@@ -31,10 +31,10 @@
     <input type='mouse' bus='ps2'/>
     <input type='keyboard' bus='ps2'/>
     <audio id='1' type='oss'>
-      <input mixingEngine='yes' fixedSettings='yes' voices='1'>
+      <input mixingEngine='yes' fixedSettings='yes' voices='1' dev='/dev/dsp0' bufferCount='30' tryPoll='yes'>
         <settings frequency='44100' channels='2' format='s16'/>
       </input>
-      <output mixingEngine='yes' fixedSettings='yes' voices='2'>
+      <output mixingEngine='yes' fixedSettings='yes' voices='2' dev='/dev/dsp1' bufferCount='30' tryPoll='no'>
         <settings frequency='22050' channels='4' format='f32'/>
       </output>
     </audio>
diff --git a/tests/qemuxml2argvdata/audio-oss-full.x86_64-latest.args b/tests/qemuxml2argvdata/audio-oss-full.x86_64-latest.args
index cf9f5077d1..fd899cad3e 100644
--- a/tests/qemuxml2argvdata/audio-oss-full.x86_64-latest.args
+++ b/tests/qemuxml2argvdata/audio-oss-full.x86_64-latest.args
@@ -36,7 +36,9 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \
 -audiodev id=audio1,driver=oss,in.mixing-engine=on,in.fixed-settings=on,\
 in.voices=1,in.buffer-length=100,in.frequency=44100,in.channels=2,\
 in.format=s16,out.mixing-engine=on,out.fixed-settings=on,out.voices=2,\
-out.buffer-length=200,out.frequency=22050,out.channels=4,out.format=f32 \
+out.buffer-length=200,out.frequency=22050,out.channels=4,out.format=f32,\
+in.dev=/dev/dsp0,in.buffer-count=50,in.try-poll=on,out.dev=/dev/dsp1,\
+out.buffer-count=30,out.try-poll=off,try-mmap=on,exclusive=on,dsp-policy=3 \
 -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\
 resourcecontrol=deny \
 -msg timestamp=on
diff --git a/tests/qemuxml2argvdata/audio-oss-full.xml b/tests/qemuxml2argvdata/audio-oss-full.xml
index 52d8810650..aa31eb9bab 100644
--- a/tests/qemuxml2argvdata/audio-oss-full.xml
+++ b/tests/qemuxml2argvdata/audio-oss-full.xml
@@ -30,11 +30,11 @@
     <controller type='pci' index='0' model='pci-root'/>
     <input type='mouse' bus='ps2'/>
     <input type='keyboard' bus='ps2'/>
-    <audio id='1' type='oss'>
-      <input mixingEngine='yes' fixedSettings='yes' voices='1' bufferLength='100'>
+    <audio id='1' type='oss' tryMMap='yes' exclusive='yes' dspPolicy='3'>
+      <input mixingEngine='yes' fixedSettings='yes' voices='1' bufferLength='100' dev='/dev/dsp0' bufferCount='50' tryPoll='yes'>
         <settings frequency='44100' channels='2' format='s16'/>
       </input>
-      <output mixingEngine='yes' fixedSettings='yes' voices='2' bufferLength='200'>
+      <output mixingEngine='yes' fixedSettings='yes' voices='2' bufferLength='200' dev='/dev/dsp1' bufferCount='30' tryPoll='no'>
         <settings frequency='22050' channels='4' format='f32'/>
       </output>
     </audio>
diff --git a/tests/qemuxml2argvdata/audio-pulseaudio-best.args b/tests/qemuxml2argvdata/audio-pulseaudio-best.args
index ad5718b242..7877fb58db 100644
--- a/tests/qemuxml2argvdata/audio-pulseaudio-best.args
+++ b/tests/qemuxml2argvdata/audio-pulseaudio-best.args
@@ -17,6 +17,10 @@ QEMU_AUDIO_DAC_VOICES=2 \
 QEMU_AUDIO_DAC_FIXED_FREQ=22050 \
 QEMU_AUDIO_DAC_FIXED_CHANNELS=4 \
 QEMU_AUDIO_DAC_FIXED_FMT=f32 \
+QEMU_PA_SOURCE=fish \
+QEMU_PA_SINK=fish \
+QEMU_PA_SAMPLES=200 \
+QEMU_PA_SERVER=%s=acme.example.org \
 /usr/bin/qemu-system-i386 \
 -name QEMUGuest1 \
 -S \
diff --git a/tests/qemuxml2argvdata/audio-pulseaudio-best.x86_64-latest.args b/tests/qemuxml2argvdata/audio-pulseaudio-best.x86_64-latest.args
index f6ccde6d59..fb58ed3e14 100644
--- a/tests/qemuxml2argvdata/audio-pulseaudio-best.x86_64-latest.args
+++ b/tests/qemuxml2argvdata/audio-pulseaudio-best.x86_64-latest.args
@@ -34,9 +34,10 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \
 "file":"libvirt-1-storage"}' \
 -device ide-cd,bus=ide.1,unit=0,drive=libvirt-1-format,id=ide0-1-0,bootindex=1 \
 -audiodev id=audio1,driver=pa,in.mixing-engine=on,in.fixed-settings=on,\
-in.voices=1,in.frequency=44100,in.channels=2,in.format=s16,\
-out.mixing-engine=on,out.fixed-settings=on,out.voices=2,out.frequency=22050,\
-out.channels=4,out.format=f32 \
+in.voices=1,in.buffer-length=200,in.frequency=44100,in.channels=2,\
+in.format=s16,out.mixing-engine=on,out.fixed-settings=on,out.voices=2,\
+out.buffer-length=200,out.frequency=22050,out.channels=4,out.format=f32,\
+in.name=fish,out.name=fish,server=acme.example.org \
 -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\
 resourcecontrol=deny \
 -msg timestamp=on
diff --git a/tests/qemuxml2argvdata/audio-pulseaudio-best.xml b/tests/qemuxml2argvdata/audio-pulseaudio-best.xml
index b75e336db3..bfc4b92e9b 100644
--- a/tests/qemuxml2argvdata/audio-pulseaudio-best.xml
+++ b/tests/qemuxml2argvdata/audio-pulseaudio-best.xml
@@ -30,11 +30,11 @@
     <controller type='pci' index='0' model='pci-root'/>
     <input type='mouse' bus='ps2'/>
     <input type='keyboard' bus='ps2'/>
-    <audio id='1' type='pulseaudio'>
-      <input mixingEngine='yes' fixedSettings='yes' voices='1'>
+    <audio id='1' type='pulseaudio' serverName='acme.example.org'>
+      <input mixingEngine='yes' fixedSettings='yes' voices='1' bufferLength='200' name='fish'>
         <settings frequency='44100' channels='2' format='s16'/>
       </input>
-      <output mixingEngine='yes' fixedSettings='yes' voices='2'>
+      <output mixingEngine='yes' fixedSettings='yes' voices='2' bufferLength='200' name='fish'>
         <settings frequency='22050' channels='4' format='f32'/>
       </output>
     </audio>
diff --git a/tests/qemuxml2argvdata/audio-pulseaudio-full.err b/tests/qemuxml2argvdata/audio-pulseaudio-full.err
index d9ceac7226..27eaa448e9 100644
--- a/tests/qemuxml2argvdata/audio-pulseaudio-full.err
+++ b/tests/qemuxml2argvdata/audio-pulseaudio-full.err
@@ -1 +1 @@
-unsupported configuration: setting audio buffer length is not supported with this QEMU
+unsupported configuration: setting audio stream name is not supported with this QEMU
diff --git a/tests/qemuxml2argvdata/audio-pulseaudio-full.x86_64-latest.args b/tests/qemuxml2argvdata/audio-pulseaudio-full.x86_64-latest.args
index 493945e608..02d0a3a9c8 100644
--- a/tests/qemuxml2argvdata/audio-pulseaudio-full.x86_64-latest.args
+++ b/tests/qemuxml2argvdata/audio-pulseaudio-full.x86_64-latest.args
@@ -36,7 +36,9 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \
 -audiodev id=audio1,driver=pa,in.mixing-engine=on,in.fixed-settings=on,\
 in.voices=1,in.buffer-length=100,in.frequency=44100,in.channels=2,\
 in.format=s16,out.mixing-engine=on,out.fixed-settings=on,out.voices=2,\
-out.buffer-length=200,out.frequency=22050,out.channels=4,out.format=f32 \
+out.buffer-length=200,out.frequency=22050,out.channels=4,out.format=f32,\
+in.name=fish,in.stream-name=food,in.latency=100,out.name=fish,\
+out.stream-name=food,out.latency=200,server=acme.example.org \
 -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\
 resourcecontrol=deny \
 -msg timestamp=on
diff --git a/tests/qemuxml2argvdata/audio-pulseaudio-full.xml b/tests/qemuxml2argvdata/audio-pulseaudio-full.xml
index 87ceefbab0..a674653982 100644
--- a/tests/qemuxml2argvdata/audio-pulseaudio-full.xml
+++ b/tests/qemuxml2argvdata/audio-pulseaudio-full.xml
@@ -30,11 +30,11 @@
     <controller type='pci' index='0' model='pci-root'/>
     <input type='mouse' bus='ps2'/>
     <input type='keyboard' bus='ps2'/>
-    <audio id='1' type='pulseaudio'>
-      <input mixingEngine='yes' fixedSettings='yes' voices='1' bufferLength='100'>
+    <audio id='1' type='pulseaudio' serverName='acme.example.org'>
+      <input mixingEngine='yes' fixedSettings='yes' voices='1' bufferLength='100' name='fish' streamName='food' latency='100'>
         <settings frequency='44100' channels='2' format='s16'/>
       </input>
-      <output mixingEngine='yes' fixedSettings='yes' voices='2' bufferLength='200'>
+      <output mixingEngine='yes' fixedSettings='yes' voices='2' bufferLength='200' name='fish' streamName='food' latency='200'>
         <settings frequency='22050' channels='4' format='f32'/>
       </output>
     </audio>
diff --git a/tests/qemuxml2argvdata/audio-sdl-best.args b/tests/qemuxml2argvdata/audio-sdl-best.args
index abdf655fe1..80b7f74829 100644
--- a/tests/qemuxml2argvdata/audio-sdl-best.args
+++ b/tests/qemuxml2argvdata/audio-sdl-best.args
@@ -17,6 +17,7 @@ QEMU_AUDIO_DAC_VOICES=2 \
 QEMU_AUDIO_DAC_FIXED_FREQ=22050 \
 QEMU_AUDIO_DAC_FIXED_CHANNELS=4 \
 QEMU_AUDIO_DAC_FIXED_FMT=f32 \
+QEMU_SDL_SAMPLES=200 \
 SDL_AUDIODRIVER=pulseaudio \
 /usr/bin/qemu-system-i386 \
 -name QEMUGuest1 \
diff --git a/tests/qemuxml2argvdata/audio-sdl-best.x86_64-latest.args b/tests/qemuxml2argvdata/audio-sdl-best.x86_64-latest.args
index d8893a7a4b..770426419a 100644
--- a/tests/qemuxml2argvdata/audio-sdl-best.x86_64-latest.args
+++ b/tests/qemuxml2argvdata/audio-sdl-best.x86_64-latest.args
@@ -36,8 +36,8 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \
 -device ide-cd,bus=ide.1,unit=0,drive=libvirt-1-format,id=ide0-1-0,bootindex=1 \
 -audiodev id=audio1,driver=sdl,in.mixing-engine=on,in.fixed-settings=on,\
 in.voices=1,in.frequency=44100,in.channels=2,in.format=s16,\
-out.mixing-engine=on,out.fixed-settings=on,out.voices=2,out.frequency=22050,\
-out.channels=4,out.format=f32 \
+out.mixing-engine=on,out.fixed-settings=on,out.voices=2,out.buffer-length=200,\
+out.frequency=22050,out.channels=4,out.format=f32 \
 -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\
 resourcecontrol=deny \
 -msg timestamp=on
diff --git a/tests/qemuxml2argvdata/audio-sdl-best.xml b/tests/qemuxml2argvdata/audio-sdl-best.xml
index 4e3f8a5c61..29523590af 100644
--- a/tests/qemuxml2argvdata/audio-sdl-best.xml
+++ b/tests/qemuxml2argvdata/audio-sdl-best.xml
@@ -34,7 +34,7 @@
       <input mixingEngine='yes' fixedSettings='yes' voices='1'>
         <settings frequency='44100' channels='2' format='s16'/>
       </input>
-      <output mixingEngine='yes' fixedSettings='yes' voices='2'>
+      <output mixingEngine='yes' fixedSettings='yes' voices='2' bufferLength='200'>
         <settings frequency='22050' channels='4' format='f32'/>
       </output>
     </audio>
diff --git a/tests/qemuxml2argvdata/audio-sdl-full.x86_64-latest.args b/tests/qemuxml2argvdata/audio-sdl-full.x86_64-latest.args
index 722aa33fa4..a642926a22 100644
--- a/tests/qemuxml2argvdata/audio-sdl-full.x86_64-latest.args
+++ b/tests/qemuxml2argvdata/audio-sdl-full.x86_64-latest.args
@@ -37,7 +37,8 @@ file=/tmp/lib/domain--1-QEMUGuest1/master-key.aes \
 -audiodev id=audio1,driver=sdl,in.mixing-engine=on,in.fixed-settings=on,\
 in.voices=1,in.buffer-length=100,in.frequency=44100,in.channels=2,\
 in.format=s16,out.mixing-engine=on,out.fixed-settings=on,out.voices=2,\
-out.buffer-length=200,out.frequency=22050,out.channels=4,out.format=f32 \
+out.buffer-length=200,out.frequency=22050,out.channels=4,out.format=f32,\
+in.buffer-count=40,out.buffer-count=50 \
 -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,\
 resourcecontrol=deny \
 -msg timestamp=on
diff --git a/tests/qemuxml2argvdata/audio-sdl-full.xml b/tests/qemuxml2argvdata/audio-sdl-full.xml
index 519cda12e3..9925d048ec 100644
--- a/tests/qemuxml2argvdata/audio-sdl-full.xml
+++ b/tests/qemuxml2argvdata/audio-sdl-full.xml
@@ -31,10 +31,10 @@
     <input type='mouse' bus='ps2'/>
     <input type='keyboard' bus='ps2'/>
     <audio id='1' type='sdl' driver='pulseaudio'>
-      <input mixingEngine='yes' fixedSettings='yes' voices='1' bufferLength='100'>
+      <input mixingEngine='yes' fixedSettings='yes' voices='1' bufferLength='100' bufferCount='40'>
         <settings frequency='44100' channels='2' format='s16'/>
       </input>
-      <output mixingEngine='yes' fixedSettings='yes' voices='2' bufferLength='200'>
+      <output mixingEngine='yes' fixedSettings='yes' voices='2' bufferLength='200' bufferCount='50'>
         <settings frequency='22050' channels='4' format='f32'/>
       </output>
     </audio>
-- 
2.29.2




[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux