Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 2a85b882 authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "usb: xhci-msm-hsic: flush pwr event completion during device removal"

parents ba6cd082 93a10794
Loading
Loading
Loading
Loading
+9 −1
Original line number Diff line number Diff line
@@ -615,6 +615,8 @@ static int mxhci_hsic_bus_suspend(struct usb_hcd *hcd)
		return -EAGAIN;
	}

	xhci_dbg_log_event(&dbg_hsic, NULL, "mxhci_hsic_bus_suspend", 0);

	init_completion(&mxhci->phy_in_lpm);

	ret = xhci_bus_suspend(hcd);
@@ -632,7 +634,7 @@ static int mxhci_hsic_bus_suspend(struct usb_hcd *hcd)
				readl_relaxed(MSM_HSIC_PORTSC));
		xhci_dbg_log_event(&dbg_hsic, NULL, "PORTLI",
				readl_relaxed(MSM_HSIC_PORTLI));
		panic("fail to get IN_L2 power event irq");
		panic("IN_L2 power event irq timedout");
	}

	xhci_dbg_log_event(&dbg_hsic, NULL, "Suspend RH",
@@ -1225,6 +1227,8 @@ static int mxhci_hsic_probe(struct platform_device *pdev)
	/* Enable HSIC PHY */
	mxhci_hsic_ulpi_write(mxhci, 0x01, MSM_HSIC_CFG_SET);

	init_completion(&mxhci->phy_in_lpm);

	device_init_wakeup(&pdev->dev, 1);
	pm_stay_awake(mxhci->dev);

@@ -1264,6 +1268,10 @@ static int mxhci_hsic_remove(struct platform_device *pdev)
	struct mxhci_hsic_hcd *mxhci = hcd_to_hsic(hcd);
	u32 reg;

	xhci_dbg_log_event(&dbg_hsic, NULL,  "mxhci_hsic_remove", 0);

	complete(&mxhci->phy_in_lpm);

	/* disable STROBE_PAD_CTL */
	reg = readl_relaxed(TLMM_GPIO_HSIC_STROBE_PAD_CTL);
	writel_relaxed(reg & 0xfdffffff, TLMM_GPIO_HSIC_STROBE_PAD_CTL);