diff options
author | Aaro Koskinen <aaro.koskinen@iki.fi> | 2013-03-13 06:10:57 -0400 |
---|---|---|
committer | Paul Walmsley <paul@pwsan.com> | 2013-03-13 06:10:57 -0400 |
commit | 13872ebb915b547b3c0a1fc04f549a1475bb7989 (patch) | |
tree | 784f4492a54c6fcaa450312abf500abd586a7c7c /arch/arm | |
parent | f6161aa153581da4a3867a2d1a7caf4be19b6ec9 (diff) |
ARM: OMAP1: fix USB host on 1710
There is a long-standing bug that OHCI USB host controller does
not respond on 1710, because of wrong clock definitions. See e.g.
http://marc.info/?l=linux-omap&m=119634441229321&w=2. All register reads
return just zeroes:
[ 1.896606] ohci ohci: OMAP OHCI
[ 1.912597] ohci ohci: new USB bus registered, assigned bus number 1
[ 1.933776] ohci ohci: irq 38, io mem 0xfffba000
[ 2.012573] ohci ohci: init err (00000000 0000)
[ 2.030334] ohci ohci: can't start
[ 2.046661] ohci ohci: startup error -75
[ 2.063201] ohci ohci: USB bus 1 deregistered
After some experiments, it seems that when changing the usb_dc_ck /
SOFT_REQ enable bit from USB_REQ_EN_SHIFT to SOFT_USB_OTG_DPLL_REQ_SHIFT
(like done also on 7XX), the USB appears to work:
[ 2.183959] ohci ohci: OMAP OHCI
[ 2.198242] ohci ohci: new USB bus registered, assigned bus number 1
[ 2.215820] ohci ohci: irq 38, io mem 0xfffba000
[ 2.324798] hub 1-0:1.0: USB hub found
[ 2.361267] hub 1-0:1.0: 3 ports detected
The patch is tested on Nokia 770.
Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Paul Walmsley <paul@pwsan.com>
Diffstat (limited to 'arch/arm')
-rw-r--r-- | arch/arm/mach-omap1/clock_data.c | 12 |
1 files changed, 1 insertions, 11 deletions
diff --git a/arch/arm/mach-omap1/clock_data.c b/arch/arm/mach-omap1/clock_data.c index cb7c6ae2e3fc..6c4f766365a2 100644 --- a/arch/arm/mach-omap1/clock_data.c +++ b/arch/arm/mach-omap1/clock_data.c | |||
@@ -543,15 +543,6 @@ static struct clk usb_dc_ck = { | |||
543 | /* Direct from ULPD, no parent */ | 543 | /* Direct from ULPD, no parent */ |
544 | .rate = 48000000, | 544 | .rate = 48000000, |
545 | .enable_reg = OMAP1_IO_ADDRESS(SOFT_REQ_REG), | 545 | .enable_reg = OMAP1_IO_ADDRESS(SOFT_REQ_REG), |
546 | .enable_bit = USB_REQ_EN_SHIFT, | ||
547 | }; | ||
548 | |||
549 | static struct clk usb_dc_ck7xx = { | ||
550 | .name = "usb_dc_ck", | ||
551 | .ops = &clkops_generic, | ||
552 | /* Direct from ULPD, no parent */ | ||
553 | .rate = 48000000, | ||
554 | .enable_reg = OMAP1_IO_ADDRESS(SOFT_REQ_REG), | ||
555 | .enable_bit = SOFT_USB_OTG_DPLL_REQ_SHIFT, | 546 | .enable_bit = SOFT_USB_OTG_DPLL_REQ_SHIFT, |
556 | }; | 547 | }; |
557 | 548 | ||
@@ -727,8 +718,7 @@ static struct omap_clk omap_clks[] = { | |||
727 | CLK(NULL, "usb_clko", &usb_clko, CK_16XX | CK_1510 | CK_310), | 718 | CLK(NULL, "usb_clko", &usb_clko, CK_16XX | CK_1510 | CK_310), |
728 | CLK(NULL, "usb_hhc_ck", &usb_hhc_ck1510, CK_1510 | CK_310), | 719 | CLK(NULL, "usb_hhc_ck", &usb_hhc_ck1510, CK_1510 | CK_310), |
729 | CLK(NULL, "usb_hhc_ck", &usb_hhc_ck16xx, CK_16XX), | 720 | CLK(NULL, "usb_hhc_ck", &usb_hhc_ck16xx, CK_16XX), |
730 | CLK(NULL, "usb_dc_ck", &usb_dc_ck, CK_16XX), | 721 | CLK(NULL, "usb_dc_ck", &usb_dc_ck, CK_16XX | CK_7XX), |
731 | CLK(NULL, "usb_dc_ck", &usb_dc_ck7xx, CK_7XX), | ||
732 | CLK(NULL, "mclk", &mclk_1510, CK_1510 | CK_310), | 722 | CLK(NULL, "mclk", &mclk_1510, CK_1510 | CK_310), |
733 | CLK(NULL, "mclk", &mclk_16xx, CK_16XX), | 723 | CLK(NULL, "mclk", &mclk_16xx, CK_16XX), |
734 | CLK(NULL, "bclk", &bclk_1510, CK_1510 | CK_310), | 724 | CLK(NULL, "bclk", &bclk_1510, CK_1510 | CK_310), |