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

Commit ab3e9d9d authored by Pavankumar Kondeti's avatar Pavankumar Kondeti
Browse files

USB: EHCI: Add a quirk to skip the suspend during test mode selection



As per the EHCI specification, all the enabled ports are put into
suspend before putting any port in test mode. This is not required
for controllers like MSM Chipidea controller which puts the PHY
into suspend when the port is suspended. The PHY has to be resumed
anyway to send the test pattern. Add a quirk to skip the port suspend
for such controllers.

Change-Id: Ib37db4790e1745b7bc822a492eecba9d25f92e88
Signed-off-by: default avatarPavankumar Kondeti <pkondeti@codeaurora.org>
parent eb6ef86f
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -1284,7 +1284,7 @@ static int ehci_hub_control (
				spin_lock_irqsave(&ehci->lock, flags);

				/* Put all enabled ports into suspend */
				while (ports--) {
				while (!ehci->no_testmode_suspend && ports--) {
					u32 __iomem *sreg =
						&ehci->regs->port_status[ports];

+1 −0
Original line number Diff line number Diff line
@@ -54,6 +54,7 @@ static int ehci_msm_reset(struct usb_hcd *hcd)

	ehci->caps = USB_CAPLENGTH;
	hcd->has_tt = 1;
	ehci->no_testmode_suspend = true;

	retval = ehci_setup(hcd);
	if (retval)
+1 −0
Original line number Diff line number Diff line
@@ -987,6 +987,7 @@ static int msm_ehci_reset(struct usb_hcd *hcd)

	ehci->caps = USB_CAPLENGTH;
	hcd->has_tt = 1;
	ehci->no_testmode_suspend = true;

	retval = ehci_setup(hcd);
	if (retval)
+1 −0
Original line number Diff line number Diff line
@@ -206,6 +206,7 @@ struct ehci_hcd { /* one per controller */
	unsigned		resume_sof_bug:1;/*Chip Idea HC*/
	unsigned		reset_sof_bug:1; /*Chip Idea HC*/
	bool			disable_cerr;
	bool			no_testmode_suspend; /* MSM Chipidea HC */
	u32			reset_delay;
	unsigned		imx28_write_fix:1; /* For Freescale i.MX28 */