The -soundhw option has been removed from Qemu but is still being used by libvirt for pcspk
Software environment
- Operating system: Arch Linux
- Architecture: x86_64
- kernel version: 6.1.33-1-lts
- libvirt version: 9.4.0
- Hypervisor and version: QEMU 8.0.2
Description of problem
Using the -soundhw
option for setting sound cards had been deprecated since QEMU 5.1 and was removed in QEMU 7.1. Libvirt still uses it to enable the pcspk device. The new way recommended by the Qemu documentation for enabling pcspk output is the -machine pcspk-audiodev=<name>
option, with name being an audio driver id.
Steps to reproduce
Add <sound model="pcspk"/>
to the devices section of a domain and try to start it.