| 文件 | 最后提交记录 | 最后更新时间 |
|---|---|---|
usbhost: introduce quirks mechanism During USB device passthrough, varying and hardware firmware quality leads to inconsistent behavior when handling set_config requests from the guest: 1. Some devices require an explicit set_config ioctl to properly activate their internal state machines, even if the target configuration is already active on the host OS 2. Other devices will crash, stall, or break functionality if they receive a redundant set_config request for the currently active configuration To resolve these compatibility issues, this patch introduces a static USB quirks mechanism: 1. Add the bitflags crate dependency to define UsbQuirk attributes (ALWAYS_SET_CONFIG and IGNORE_SET_CONFIG) 2. Implement a OnceLock based table to map specific device Vendor IDs and Product IDs (VID/PID) to their corresponding quirks 3. Update the UsbHost struct to query and store device quirks during the attachment phase 4. Refactor the set_config handler to fetch the device's current active configuration and evaluate it against the device's specific quirks before deciding whether to dispatch the actual ioctl to the host Signed-off-by: Fan Xuan Zhe <fanxuanzhe@huawei.com> (cherry picked from commit 97c83f638a995fcdccac216de07b4345deb6d663) | 7 天前 | |
usb/xhci: optimize async worker thread implementation Currently, the xhci async worker thread releys on the Drop impl of the xhciDevice to notify thread exit, which can be optimized by using iterator manner of the Receiver in mpsc module, so let's do it. Signed-off-by: Fan Xuan Zhe <fanxuanzhe@huawei.com> (cherry picked from commit 91681c45e71fa841ec74bd001e9d2be7b5870258) | 7 天前 | |
camera: fix deadlock during concurrent device detach and vm pause There is an ABBA deadlock issue when a usb camera is being detached at the exact same time the VM is paused. The deadlock happens in the following sequence: 1. xHCI detach process: acquire the Camera device lock, then calls unregister_vm_pause_notifier, waiting for the global NOTIFIER_MANAGER lock. 2. vm pause process: holds the global NOTIFIER_MANAGER lock, iterates through callbacks, and attemps to acquire the Camera device lock inside the closure to pause the backend. This commit breaks the circular lock dependency by narrowing the lock granularity. Instead of moving the cloned Camera into the pause closure, we now only clone and capture the camera_backend. Signed-off-by: Fan Xuan Zhe <fanxuanzhe@huawei.com> (cherry picked from commit dd5b9520c86b04a980bb7c0eec46e0ac7a062434) | 7 天前 | |
camera: support for NV12 format allow NV12 format of host side transfered to guest. Signed-off-by: zhanghan64 <zhanghan64@huawei.com> | 2 年前 | |
introduce usb device consumer. In order to support keyboard wire control, we introduce usb device consumer. Currently, support the following functions: Play/Pause Scan Previous track Scan Next Track Stop Signed-off-by: Fei Xu <xufei30@huawei.com> | 8 个月前 | |
migration: add restored version when restoring vm state Add restored version when restoring vm state. Signed-off-by: Yan Wang <wangyan122@huawei.com> | 4 个月前 | |
usb: Add support for USB Stream device passthrough Add alloc_streams and free_streams to UsbDevice trait and implement them for USB Host device, thus allowing stream device passthrough. Signed-off-by: goriainovstanislav <goriainov.stanislav@huawei-partners.com> | 4 个月前 | |
Refactory: move pci/sysbus to devices lib Move pci/sysbus to devices lib. Signed-off-by: liuxiangdong <liuxiangdong5@huawei.com> | 2 年前 | |
hid device base: add memory snapshot ut case Add relevant ut case for hid device base's memory snapshot capabilities. Signed-off-by: Fan Xuan Zhe <fanxuanzhe@huawei.com> | 4 个月前 | |
snapshot: adapt to version param in ut case Add _version param in ut case for Xhci/Keyboard/Tablet devices. Signed-off-by: Fan Xuan Zhe <fanxuanzhe@huawei.com> Signed-off-by: Fei Xu <xufei30@huawei.com> | 4 个月前 | |
usbhost: introduce quirks mechanism During USB device passthrough, varying and hardware firmware quality leads to inconsistent behavior when handling set_config requests from the guest: 1. Some devices require an explicit set_config ioctl to properly activate their internal state machines, even if the target configuration is already active on the host OS 2. Other devices will crash, stall, or break functionality if they receive a redundant set_config request for the currently active configuration To resolve these compatibility issues, this patch introduces a static USB quirks mechanism: 1. Add the bitflags crate dependency to define UsbQuirk attributes (ALWAYS_SET_CONFIG and IGNORE_SET_CONFIG) 2. Implement a OnceLock based table to map specific device Vendor IDs and Product IDs (VID/PID) to their corresponding quirks 3. Update the UsbHost struct to query and store device quirks during the attachment phase 4. Refactor the set_config handler to fetch the device's current active configuration and evaluate it against the device's specific quirks before deciding whether to dispatch the actual ioctl to the host Signed-off-by: Fan Xuan Zhe <fanxuanzhe@huawei.com> (cherry picked from commit 97c83f638a995fcdccac216de07b4345deb6d663) | 7 天前 | |
usbhost: introduce quirks mechanism During USB device passthrough, varying and hardware firmware quality leads to inconsistent behavior when handling set_config requests from the guest: 1. Some devices require an explicit set_config ioctl to properly activate their internal state machines, even if the target configuration is already active on the host OS 2. Other devices will crash, stall, or break functionality if they receive a redundant set_config request for the currently active configuration To resolve these compatibility issues, this patch introduces a static USB quirks mechanism: 1. Add the bitflags crate dependency to define UsbQuirk attributes (ALWAYS_SET_CONFIG and IGNORE_SET_CONFIG) 2. Implement a OnceLock based table to map specific device Vendor IDs and Product IDs (VID/PID) to their corresponding quirks 3. Update the UsbHost struct to query and store device quirks during the attachment phase 4. Refactor the set_config handler to fetch the device's current active configuration and evaluate it against the device's specific quirks before deciding whether to dispatch the actual ioctl to the host Signed-off-by: Fan Xuan Zhe <fanxuanzhe@huawei.com> (cherry picked from commit 97c83f638a995fcdccac216de07b4345deb6d663) | 7 天前 | |
uas: Support real BOT interface for UAS alternate setting Replace fake BOT interface hack with a real BOT interface as UAS alternate setting. Usb-uas device now supports both protocols. Signed-off-by: goriainovstanislav <goriainov.stanislav@huawei-partners.com> | 1 年前 | |
snapshot: adapt to version param in ut case Add _version param in ut case for Xhci/Keyboard/Tablet devices. Signed-off-by: Fan Xuan Zhe <fanxuanzhe@huawei.com> Signed-off-by: Fei Xu <xufei30@huawei.com> | 4 个月前 | |
xhci: Rename submit transfer to complete transfer The name "submit_transfer" suggests that the transfer hasn't even started yet, when, in fact, it is already finished. Rename it to "complete". Signed-off-by: goriainovstanislav <goriainov.stanislav@huawei-partners.com> | 4 个月前 |
| 文件 | 最后提交记录 | 最后更新时间 |
|---|---|---|
| 7 天前 | ||
| 7 天前 | ||
| 7 天前 | ||
| 2 年前 | ||
| 8 个月前 | ||
| 4 个月前 | ||
| 4 个月前 | ||
| 2 年前 | ||
| 4 个月前 | ||
| 4 个月前 | ||
| 7 天前 | ||
| 7 天前 | ||
| 1 年前 | ||
| 4 个月前 | ||
| 4 个月前 |