/
0003-pandaboard-usb-let-ehci-driver-initialize-usb-phy.patch
70 lines (65 loc) · 2.53 KB
/
0003-pandaboard-usb-let-ehci-driver-initialize-usb-phy.patch
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
From 6ccba720d17fa60929f4e895e9086199f5d5cd31 Mon Sep 17 00:00:00 2001
From: Scott Ellis <scott@jumpnowtek.com>
Date: Tue, 6 Jan 2015 05:16:16 -0500
Subject: [PATCH 3/6] pandaboard: usb: let ehci driver initialize usb phy
---
sys/arm/conf/PANDABOARD | 2 +-
sys/arm/ti/usb/omap_ehci.c | 1 +
sys/boot/fdt/dts/arm/pandaboard.dts | 15 ++++++++++-----
3 files changed, 12 insertions(+), 6 deletions(-)
diff --git sys/arm/conf/PANDABOARD sys/arm/conf/PANDABOARD
index fb50ebd..62fb47a 100644
--- sys/arm/conf/PANDABOARD
+++ sys/arm/conf/PANDABOARD
@@ -27,7 +27,7 @@ ident PANDABOARD
hints "PANDABOARD.hints"
-include "../ti/omap4/pandaboard/std.pandaboard"
+include "../ti/omap4/std.omap4"
makeoptions MODULES_OVERRIDE=""
makeoptions WITHOUT_MODULES="ahc"
diff --git sys/arm/ti/usb/omap_ehci.c sys/arm/ti/usb/omap_ehci.c
index f0a1c3e..79f97bb 100644
--- sys/arm/ti/usb/omap_ehci.c
+++ sys/arm/ti/usb/omap_ehci.c
@@ -430,6 +430,7 @@ omap_ehci_init(struct omap_ehci_softc *isc)
if (isc->port_mode[0] == EHCI_HCD_OMAP_MODE_PHY) {
ti_prcm_clk_set_source(USBP1_PHY_CLK, EXT_CLK);
ti_prcm_clk_enable(USBP1_PHY_CLK);
+ ti_prcm_clk_enable(AUX3_CLK);
} else if (isc->port_mode[0] == EHCI_HCD_OMAP_MODE_TLL)
ti_prcm_clk_enable(USBP1_UTMI_CLK);
else if (isc->port_mode[0] == EHCI_HCD_OMAP_MODE_HSIC)
diff --git sys/boot/fdt/dts/arm/pandaboard.dts sys/boot/fdt/dts/arm/pandaboard.dts
index a4303ad..7a2fa31 100644
--- sys/boot/fdt/dts/arm/pandaboard.dts
+++ sys/boot/fdt/dts/arm/pandaboard.dts
@@ -134,7 +134,11 @@
ehci {
compatible = "ti,usb-ehci", "usb-ehci";
/*
- * USB port PHY configuration is a tuple: <mode, reset, gpio_pin>
+ * USB port PHY configuration is a tuple consisting of either
+ * <mode, reset, gpio_pin>
+ * or
+ * <mode, reset, gpio_pin1, gpio_pin2>
+ *
* mode is one of the following values:
* 0 - unknown
* 1 - PHY
@@ -142,11 +146,12 @@
* 3 - HSIC
*
* reset indicates (if non-zero) if port reset is required
- * gpio_pin - GPIO pin that is used to perform reset
+ * gpio_pin - GPIO pin(s) that is used to perform reset
+ * the pandaboard uses 2 reset pins
*/
- phy-config = < 1 0 0
- 0 0 0
- 0 0 0>;
+ phy-config = < 1 1 62 1
+ 0 0 0 0
+ 0 0 0 0 >;
reg = < 0x4a064c00 0x100 /* EHCI regs */
0x4a064000 0x700 /* UHH regs */
0x4a062000 0x1000>; /* TLL regs */