IF YOU WOULD LIKE TO GET AN ACCOUNT, please write an
email to Administrator. User accounts are meant only to access repo
and report issues and/or generate pull requests.
This is a purpose-specific Git hosting for
BaseALT
projects. Thank you for your understanding!
Только зарегистрированные пользователи имеют доступ к сервису!
Для получения аккаунта, обратитесь к администратору.
in the backend, we allow up to 14 usb ports, but only if the vm can
use the qemu-xhci controller which is only possible since machine
version 7.1 and if the ostype is l26 or windows > 7
for this we introduce two helpers:
* qemu_min_version: modeled after the signature of 'min_version' from
qemu-server, expects two arrays of versions and returns true if
the first parameter is equal or greater than the second version
* get_max_usb_count looks at the given ostype and machine string
and returns the proper maximum number
since we don't currently have the actual running version of the vm in
the gui, this is only a heuristic for running vms. but since the actual
running version could only be lower if none is set (e.g. for
migrated/long-running vms) we allow more in the gui and the backend will
do the proper thing (either hotplug it, or make it a pending change)
Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
Enable USB3 by default. There are no restrictions anymore that the speed
of the dev must match the USB3 speed. The xhci controller can deal with
USB 2 and 1 devices. USB3 devices can be plugged in a USB2 (ehci)
controller. As discussed in [0]
When using a USB device for SPICE passthrough my tests showed that USB2
devices connecting to the xhci controller work but a USB3 device passed
via Spice cannot connect to an ehci controller (no USB3 enabled).
qemu-server 6.0-9 supports USB3 also for Spice USB passthrough. See
commit 733234b [1].
All this means we can get rid of the separate handling of USB3 and non
USB3 devices and leave the decision to the user if USB3 should be
enabled or not.
[0]: https://pve.proxmox.com/pipermail/pve-devel/2019-September/039131.html
[1]: https://git.proxmox.com/?p=qemu-server.git;a=commitdiff;h=733234be04d585febd74c655d8b82d17ebf9e133
Signed-off-by: Aaron Lauterer <a.lauterer@proxmox.com>
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
As getUSBValue() always added the "usb3" property if the selected
device was recognized as USB3. But we can now also pass such a device
as USB2 so lift this restriction - which also fixes a bug for USB3
selected devices with the USB3 checkbox set.
The solution also avoids the me.down query, which is nice too.
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
split the long ternary operation into a common if/else, to make it
readable.
Also, remove the usb3field.isDisabled check as:
1. we do not disable it anywhere anymore
2. if we would, it makes sense to do this anyhow
Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
Instead of having two times the check if the USB3 setting needs to be
added to the config string it is now checked at one place only.
If USB3 is checked for a non USB3 device it will be attached to the USB2
root hub of the xhci controller.
Signed-off-by: Aaron Lauterer <a.lauterer@proxmox.com>
the edit window has 3 radiobuttons (spice,device,port)
and a checkbox for usb3 (which gets disabled and checked
if you choose a usb3 device)
also it makes use of the help feature
Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>