Re: [PATCH 12/13] usb: dwc2: hcd: use new USB_RESUME_TIMEOUT
On Sat, Feb 14, 2015 at 05:46:05PM +0200, Laurent Pinchart wrote: Hi Felipe, Thank you for the patch. On Friday 13 February 2015 15:07:54 Felipe Balbi wrote: Make sure we're using the new macro, so our resume signaling will always pass certification. Signed-off-by: Felipe Balbi ba...@ti.com --- drivers/usb/dwc2/hcd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/usb/dwc2/hcd.c b/drivers/usb/dwc2/hcd.c index c78c8740db1d..758b7e0380f6 100644 --- a/drivers/usb/dwc2/hcd.c +++ b/drivers/usb/dwc2/hcd.c @@ -1521,7 +1521,7 @@ static int dwc2_hcd_hub_control(struct dwc2_hsotg *hsotg, u16 typereq, dev_dbg(hsotg-dev, ClearPortFeature USB_PORT_FEAT_SUSPEND\n); writel(0, hsotg-regs + PCGCTL); - usleep_range(2, 4); + msleep(USB_RESUME_TIMEOUT); In order not to increase the number of wake events, shouldn't we use usleep_range() at least for drivers that already use it ? we shouldn't use usleep_range() for anything larger than 10ms anyway. -- balbi signature.asc Description: Digital signature
Re: [PATCH 12/13] usb: dwc2: hcd: use new USB_RESUME_TIMEOUT
Hi Felipe, Thank you for the patch. On Friday 13 February 2015 15:07:54 Felipe Balbi wrote: Make sure we're using the new macro, so our resume signaling will always pass certification. Signed-off-by: Felipe Balbi ba...@ti.com --- drivers/usb/dwc2/hcd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/usb/dwc2/hcd.c b/drivers/usb/dwc2/hcd.c index c78c8740db1d..758b7e0380f6 100644 --- a/drivers/usb/dwc2/hcd.c +++ b/drivers/usb/dwc2/hcd.c @@ -1521,7 +1521,7 @@ static int dwc2_hcd_hub_control(struct dwc2_hsotg *hsotg, u16 typereq, dev_dbg(hsotg-dev, ClearPortFeature USB_PORT_FEAT_SUSPEND\n); writel(0, hsotg-regs + PCGCTL); - usleep_range(2, 4); + msleep(USB_RESUME_TIMEOUT); In order not to increase the number of wake events, shouldn't we use usleep_range() at least for drivers that already use it ? hprt0 = dwc2_read_hprt0(hsotg); hprt0 |= HPRT0_RES; -- Regards, Laurent Pinchart -- To unsubscribe from this list: send the line unsubscribe linux-usb in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
[PATCH 12/13] usb: dwc2: hcd: use new USB_RESUME_TIMEOUT
Make sure we're using the new macro, so our resume signaling will always pass certification. Signed-off-by: Felipe Balbi ba...@ti.com --- drivers/usb/dwc2/hcd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/usb/dwc2/hcd.c b/drivers/usb/dwc2/hcd.c index c78c8740db1d..758b7e0380f6 100644 --- a/drivers/usb/dwc2/hcd.c +++ b/drivers/usb/dwc2/hcd.c @@ -1521,7 +1521,7 @@ static int dwc2_hcd_hub_control(struct dwc2_hsotg *hsotg, u16 typereq, dev_dbg(hsotg-dev, ClearPortFeature USB_PORT_FEAT_SUSPEND\n); writel(0, hsotg-regs + PCGCTL); - usleep_range(2, 4); + msleep(USB_RESUME_TIMEOUT); hprt0 = dwc2_read_hprt0(hsotg); hprt0 |= HPRT0_RES; -- 2.3.0 -- To unsubscribe from this list: send the line unsubscribe linux-usb in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html