[PATCH] usb: chipidea: udc: first start device on pullup

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Don't start hw_device_state on udc_start. The gadget framework has
the prepared pullup callback for this. This is necessary if we use gadgets
which need to be enabled after an userspace application got prepared, or
other delayed conditiions have passed.

Signed-off-by: Michael Grzeschik <m.grzeschik@xxxxxxxxxxxxxx>
---

Hi Peter,

I checked ci_udc_start again and realized that one problem is
that we ignore the pullup call and start the device on udc_start.

What do you think of the following patch? Any objections?

 drivers/usb/chipidea/udc.c | 5 -----
 1 file changed, 5 deletions(-)

diff --git a/drivers/usb/chipidea/udc.c b/drivers/usb/chipidea/udc.c
index b34c819..e673263 100644
--- a/drivers/usb/chipidea/udc.c
+++ b/drivers/usb/chipidea/udc.c
@@ -1647,11 +1647,6 @@ static int ci_udc_start(struct usb_gadget *gadget,
 		return retval;
 	}
 
-	retval = hw_device_state(ci, ci->ep0out->qh.dma);
-	spin_unlock_irqrestore(&ci->lock, flags);
-	if (retval)
-		pm_runtime_put_sync(&ci->gadget.dev);
-
 	return retval;
 }
 
-- 
1.8.4.2

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux