usb: host: xhci-dbg: HCIVERSION should be a binary number
Subsystems (3)
A message that is not in the archive (sent off-list or not yet received): [email protected]
PATCH 3/4 usb: host: xhci-dbg: HCIVERSION should be a binary number
From: Peter Chen <[email protected]>
According to xHCI spec, HCIVERSION containing a BCD encoding of the xHCI specification revision number, 0100h corresponds to xHCI version 1.0. Change "100" as "0x100".
1.1 capability register")
--- drivers/usb/host/xhci-dbg.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/usb/host/xhci-dbg.c +1 -1
@@ -109,7 +109,7 @@ static void xhci_print_cap_regs(struct xhci_hcd *xhci)xhci_dbg (xhci,"RTSOFF 0x%x:\n" , temp &RTSOFF_MASK );/* xhci 1.1 controllers have the HCCPARAMS2 register */ -if (hci_version >100 ) { +if (hci_version >0x100 ) { temp =readl (&xhci->cap_regs->hcc_params2);xhci_dbg (xhci,"HCC PARAMS2 0x%x:\n" , (unsigned int ) temp); xhci_dbg(xhci, " HC %s Force save context capability",
Signature · 1 line
1.9.1
PATCH 4/4 usb: host: xhci-plat: Fix timeout on removal of hot pluggable xhci controllers
In reply to a message not in the archiveFrom: Guenter Roeck <[email protected]>
Upstream commit 98d74f9ceaef ("xhci: fix 10 second timeout on removal of PCI hotpluggable xhci controllers") fixes a problem with hot pluggable PCI xhci controllers which can result in excessive timeouts, to the point where the system reports a deadlock.
The same problem is seen with hot pluggable xhci controllers using the xhci-plat driver, such as the driver used for Type-C ports on rk3399. Similar to hot-pluggable PCI controllers, the driver for this chip removes the xhci controller from the system when the Type-C cable is disconnected.
The solution for PCI devices works just as well for non-PCI devices and avoids the problem.
--- drivers/usb/host/xhci-plat.c | 2 ++ 1 file changed, 2 insertions(+)
drivers/usb/host/xhci-plat.c +2 -0
@@ -286,6 +286,8 @@ static int xhci_plat_remove(struct platform_device *dev)struct xhci_hcd *xhci =hcd_to_xhci (hcd);struct clk *clk = xhci->clk; + xhci->xhc_state |=XHCI_STATE_REMOVING ; +usb_remove_hcd (xhci->shared_hcd);usb_phy_shutdown (hcd->usb_phy);
Signature · 1 line
1.9.1