diff options
| -rw-r--r-- | arch/arm/mach-pxa/pxa27x.c | 7 | ||||
| -rw-r--r-- | drivers/usb/host/ohci-pxa27x.c | 11 |
2 files changed, 14 insertions, 4 deletions
diff --git a/arch/arm/mach-pxa/pxa27x.c b/arch/arm/mach-pxa/pxa27x.c index bf01e14098f5..3e4ab2279c99 100644 --- a/arch/arm/mach-pxa/pxa27x.c +++ b/arch/arm/mach-pxa/pxa27x.c | |||
| @@ -34,6 +34,13 @@ | |||
| 34 | #include "devices.h" | 34 | #include "devices.h" |
| 35 | #include "clock.h" | 35 | #include "clock.h" |
| 36 | 36 | ||
| 37 | void pxa27x_clear_otgph(void) | ||
| 38 | { | ||
| 39 | if (cpu_is_pxa27x() && (PSSR & PSSR_OTGPH)) | ||
| 40 | PSSR |= PSSR_OTGPH; | ||
| 41 | } | ||
| 42 | EXPORT_SYMBOL(pxa27x_clear_otgph); | ||
| 43 | |||
| 37 | /* Crystal clock: 13MHz */ | 44 | /* Crystal clock: 13MHz */ |
| 38 | #define BASE_CLK 13000000 | 45 | #define BASE_CLK 13000000 |
| 39 | 46 | ||
diff --git a/drivers/usb/host/ohci-pxa27x.c b/drivers/usb/host/ohci-pxa27x.c index 8530c6e9b770..1fd77933a4c6 100644 --- a/drivers/usb/host/ohci-pxa27x.c +++ b/drivers/usb/host/ohci-pxa27x.c | |||
| @@ -25,7 +25,6 @@ | |||
| 25 | #include <linux/clk.h> | 25 | #include <linux/clk.h> |
| 26 | 26 | ||
| 27 | #include <mach/hardware.h> | 27 | #include <mach/hardware.h> |
| 28 | #include <mach/pxa2xx-regs.h> /* FIXME: for PSSR */ | ||
| 29 | #include <mach/ohci.h> | 28 | #include <mach/ohci.h> |
| 30 | 29 | ||
| 31 | /* | 30 | /* |
| @@ -182,6 +181,12 @@ static inline void pxa27x_setup_hc(struct pxaohci_platform_data *inf) | |||
| 182 | UHCRHDA = uhcrhda; | 181 | UHCRHDA = uhcrhda; |
| 183 | } | 182 | } |
| 184 | 183 | ||
| 184 | #ifdef CONFIG_CPU_PXA27x | ||
| 185 | extern void pxa27x_clear_otgph(void); | ||
| 186 | #else | ||
| 187 | #define pxa27x_clear_otgph() do {} while (0) | ||
| 188 | #endif | ||
| 189 | |||
| 185 | static int pxa27x_start_hc(struct device *dev) | 190 | static int pxa27x_start_hc(struct device *dev) |
| 186 | { | 191 | { |
| 187 | int retval = 0; | 192 | int retval = 0; |
| @@ -212,9 +217,7 @@ static int pxa27x_start_hc(struct device *dev) | |||
| 212 | UHCHIE = (UHCHIE_UPRIE | UHCHIE_RWIE); | 217 | UHCHIE = (UHCHIE_UPRIE | UHCHIE_RWIE); |
| 213 | 218 | ||
| 214 | /* Clear any OTG Pin Hold */ | 219 | /* Clear any OTG Pin Hold */ |
| 215 | if (cpu_is_pxa27x() && (PSSR & PSSR_OTGPH)) | 220 | pxa27x_clear_otgph(); |
| 216 | PSSR |= PSSR_OTGPH; | ||
| 217 | |||
| 218 | return 0; | 221 | return 0; |
| 219 | } | 222 | } |
| 220 | 223 | ||
