summaryrefslogtreecommitdiffstats
path: root/drivers/usb/chipidea
diff options
context:
space:
mode:
authorRichard Zhao <richard.zhao@freescale.com>2012-09-12 14:58:07 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-09-12 11:20:38 -0700
commit86ad01a907d7856edc07d8b49260c39520c0e932 (patch)
tree5669d59eb44bb4b8f778bbdbb58a4b41b2e32da1 /drivers/usb/chipidea
parentb4dbb258b67b12fff4c9df56983934e11813c404 (diff)
downloadop-kernel-dev-86ad01a907d7856edc07d8b49260c39520c0e932.zip
op-kernel-dev-86ad01a907d7856edc07d8b49260c39520c0e932.tar.gz
USB: chipidea: delay 2ms before read ID status at probe time
The ID pin needs 1ms debounce time, even at probe time. We delay 2ms to be on the safe side. Tested-by: Michael Grzeschik <m.grzeschik@pengutronix.de> Tested-by: Marc Kleine-Budde <mkl@pengutronix.de> Signed-off-by: Richard Zhao <richard.zhao@freescale.com> Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/usb/chipidea')
-rw-r--r--drivers/usb/chipidea/core.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/usb/chipidea/core.c b/drivers/usb/chipidea/core.c
index 1083585..3c3ed77 100644
--- a/drivers/usb/chipidea/core.c
+++ b/drivers/usb/chipidea/core.c
@@ -462,6 +462,8 @@ static int __devinit ci_hdrc_probe(struct platform_device *pdev)
if (ci->roles[CI_ROLE_HOST] && ci->roles[CI_ROLE_GADGET]) {
ci->is_otg = true;
+ /* ID pin needs 1ms debouce time, we delay 2ms for safe */
+ mdelay(2);
ci->role = ci_otg_role(ci);
} else {
ci->role = ci->roles[CI_ROLE_HOST]
OpenPOWER on IntegriCloud