mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2025-05-23 07:33:47 +00:00
DM USB: xHCI: fix a crash issue when usb device is disconnected
This is an issue result from incomplete process logic of commit: "ba68bd4 DM USB: xHCI: fix enumeration error after rebooting". This patch is used to fix it. Signed-off-by: Xiaoguang Wu <xiaoguang.wu@intel.com> Reviewed-by: Liang Yang <liang3.yang@intel.com> Acked-by: Yu Wang <yu1.wang@intel.com> Tracked-On: #1425
This commit is contained in:
parent
2b53acb5f8
commit
e0728f4b60
@ -704,7 +704,9 @@ pci_xhci_native_usb_dev_disconn_cb(void *hci_data, void *dev_data)
|
||||
if (xdev->slots[slot] == edev)
|
||||
break;
|
||||
|
||||
assert(status == VPORT_EMULATED || status == VPORT_CONNECTED);
|
||||
assert(VPORT_STATE(status) == VPORT_EMULATED ||
|
||||
VPORT_STATE(status) == VPORT_CONNECTED);
|
||||
|
||||
xdev->port_map_tbl[di.bus][di.port] = VPORT_NUM_STATE(VPORT_ASSIGNED,
|
||||
0);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user