On 6/26/23 14:13, Michal Privoznik wrote:
> Historically, the way to set PC speaker for a guest was to pass:
> 
>   -soundhw pcspk
> 
> but as of QEMU commit v5.1.0-rc0~28^2~3 this is deprecated and we
> should use:
> 
>   -machine pcspk-audiodev=$id
> 
> instead. The old way was then removed in commit v7.1.0-rc0~99^2~3.
> 
> Now, ideally we would have a capability selecting whether we talk
> to a QEMU that understands the new way or not. But it's not that
> simple - the machine attribute is just an alias to the .audiodev=
> attribute of 'isa-pcspk' object and both are created in
> pc_machine_initfn() function, i.e. not then the PC_MACHINE() class
> is initialized, but when it's instantiated. IOW, it's not possible
> for us to query whether we're dealing with older or newer QEMU.
> 
> But given that the newer version is supported since v5.1.0 and the
> minimal version we require is v4.2.0 (i.e. there are two releases
> which don't understand the newer cmd line) and how frequently this
> feature is (un-)used (the issue was reported after ~1 year since it
> stopped working), I believe we can live without any capability and
> just use the newer cmd line unconditionally.
> 
> Resolves: https://gitlab.com/libvirt/libvirt/-/issues/490
> Signed-off-by: Michal Privoznik <mpriv...@redhat.com>
> ---
>  src/qemu/qemu_command.c                       | 57 ++++++++++++-------
>  .../sound-device.x86_64-4.2.0.args            |  3 +-
>  .../sound-device.x86_64-latest.args           |  3 +-
>  3 files changed, 38 insertions(+), 25 deletions(-)


Polite ping.

Michal

Reply via email to