mirror of
https://git.proxmox.com/git/qemu-server
synced 2025-05-28 18:02:07 +00:00
cfg2cmd: Add the audiodev property to audio devs
With Qemu 4.2 a new `audiodev` property was introduced [0] to explicitly specify the backend to be used for the audio device. This is accompanied with a warning that the fallback to the default audio backend is deprecated. [0] https://wiki.qemu.org/ChangeLog/4.2#Audio Signed-off-by: Aaron Lauterer <a.lauterer@proxmox.com>
This commit is contained in:
parent
818c3b8d91
commit
940e2a3a06
@ -3256,11 +3256,11 @@ sub config_to_command {
|
||||
|
||||
my $id = $audio->{dev_id};
|
||||
if ($audio->{dev} eq 'AC97') {
|
||||
push @$devices, '-device', "AC97,id=${id}${audiopciaddr}";
|
||||
push @$devices, '-device', "AC97,id=${id}${audiopciaddr},audiodev=$audio->{backend_id}";
|
||||
} elsif ($audio->{dev} =~ /intel\-hda$/) {
|
||||
push @$devices, '-device', "$audio->{dev},id=${id}${audiopciaddr}";
|
||||
push @$devices, '-device', "hda-micro,id=${id}-codec0,bus=${id}.0,cad=0";
|
||||
push @$devices, '-device', "hda-duplex,id=${id}-codec1,bus=${id}.0,cad=1";
|
||||
push @$devices, '-device', "hda-micro,id=${id}-codec0,bus=${id}.0,cad=0,audiodev=$audio->{backend_id}";
|
||||
push @$devices, '-device', "hda-duplex,id=${id}-codec1,bus=${id}.0,cad=1,audiodev=$audio->{backend_id}";
|
||||
} else {
|
||||
die "unkown audio device '$audio->{dev}', implement me!";
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user