|
@@ -362,14 +362,16 @@ static int xhci_plat_remove(struct platform_device *dev)
|
|
|
struct xhci_hcd *xhci = hcd_to_xhci(hcd);
|
|
|
struct clk *clk = xhci->clk;
|
|
|
struct clk *reg_clk = xhci->reg_clk;
|
|
|
+ struct usb_hcd *shared_hcd = xhci->shared_hcd;
|
|
|
|
|
|
xhci->xhc_state |= XHCI_STATE_REMOVING;
|
|
|
|
|
|
- usb_remove_hcd(xhci->shared_hcd);
|
|
|
+ usb_remove_hcd(shared_hcd);
|
|
|
+ xhci->shared_hcd = NULL;
|
|
|
usb_phy_shutdown(hcd->usb_phy);
|
|
|
|
|
|
usb_remove_hcd(hcd);
|
|
|
- usb_put_hcd(xhci->shared_hcd);
|
|
|
+ usb_put_hcd(shared_hcd);
|
|
|
|
|
|
clk_disable_unprepare(clk);
|
|
|
clk_disable_unprepare(reg_clk);
|