DM USB: xHCI: fix bug in port unassigning function

The function for port unassigning: pci_xhci_clr_native_port_assigned
should reset the 'info' member to all zero when it is called.

Tracked-On: #1434
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>
This commit is contained in:
Xiaoguang Wu 2018-10-22 13:17:43 +08:00 committed by wenlingz
parent d7008408d0
commit 08a7227fe6

View File

@ -588,6 +588,7 @@ pci_xhci_clr_native_port_assigned(struct pci_xhci_vdev *xdev,
if (i >= 0) {
xdev->native_ports[i].state = VPORT_FREE;
xdev->native_ports[i].vport = 0;
memset(&xdev->native_ports[i].info, 0, sizeof(*info));
}
}