PS/2 mouse and keyboard not disabled when adding USB devices

Host environment

  • Operating system: ArchLinux
  • OS/kernel version: Linux x280 6.6.1-arch1-1 #1 SMP PREEMPT_DYNAMIC Wed, 08 Nov 2023 16:05:38 +0000 x86_64 GNU/Linux
  • Architecture: amd64
  • QEMU flavor: qemu-system-x86_64
  • QEMU version: 8.1.2
  • QEMU command line:
    qemu-system-x86_64 -cpu host -M q35 -device qemu-xhci,id=xhci -usbdevice tablet -usbdevice keyboard -enable-kvm -smp 12 -m 8G -hda haiku.qcow2
    or
    qemu-system-x86_64 -cpu host -M q35 -device qemu-xhci,id=xhci -device usb-tablet -device usb-kbd -enable-kvm -smp 12 -m 8G -hda haiku.qcow2

Emulated/Virtualized environment

  • Operating system: Haiku r1~beta4_hrev57383
  • OS/kernel version: Haiku shredder 1 hrev57383 Nov 16 2023 07:32:15 x86_64 x86_64 Haiku
  • Architecture: amd64

Description of problem

Documentation (such as https://www.qemu.org/docs/master/system/qemu-manpage.html or https://www.qemu.org/docs/master/system/devices/usb.html) says that enabling a USB keyboard or mouse (or tablet) will disable the PS/2 equivalent, but it seems both are present instead.

Steps to reproduce

  1. Pass a -usbdevice or -device option to QEMU.
  2. Boot Haiku.
  3. Find two identical devices in Preferences > Input, both Extended PS/2 Mouse 1 and USB Tablet 1, as well as AT Keyboard 1 and USB Keyboard 1.

Additional information

The content of /var/log/syslog, which shows discovery of PS/2 devices: syslog.zst