1 From 6c2374c768e0eacba197e242e8793d93846dc762 Mon Sep 17 00:00:00 2001
2 From: John Crispin <blogic@openwrt.org>
3 Date: Wed, 11 Apr 2012 18:43:50 +0200
4 Subject: [PATCH 70/73] MIPS: lantiq: fix dwc_otg usb for ase
6 changed irq number and pmu settings. little bit of fiddling to get the now variable
9 Signed-off-by: Conor O'Gorman <i@conorogorman.net>
11 .../mips/include/asm/mach-lantiq/xway/lantiq_irq.h | 1 +
12 drivers/usb/dwc_otg/dwc_otg_driver.c | 3 +++
13 drivers/usb/dwc_otg/dwc_otg_ifx.c | 5 ++++-
14 3 files changed, 8 insertions(+), 1 deletions(-)
16 --- a/arch/mips/include/asm/mach-lantiq/xway/lantiq_irq.h
17 +++ b/arch/mips/include/asm/mach-lantiq/xway/lantiq_irq.h
20 #define LTQ_TIMER6_INT (INT_NUM_IM1_IRL0 + 23)
21 #define LTQ_USB_INT (INT_NUM_IM1_IRL0 + 22)
22 +#define LTQ_USB_ASE_INT (INT_NUM_IM0_IRL0 + 31)
23 #define LTQ_USB_OC_INT (INT_NUM_IM4_IRL0 + 23)
25 #define MIPS_CPU_TIMER_IRQ 7
26 --- a/drivers/usb/dwc_otg/dwc_otg_driver.c
27 +++ b/drivers/usb/dwc_otg/dwc_otg_driver.c
28 @@ -860,6 +860,9 @@ static int __init dwc_otg_init(void)
30 printk(KERN_INFO "%s: version %s\n", dwc_driver_name, DWC_DRIVER_VERSION);
33 + dwc_irq = LTQ_USB_ASE_INT;
36 retval = ifx_usb_hc_init(dwc_iomem_base, dwc_irq);
38 --- a/drivers/usb/dwc_otg/dwc_otg_ifx.c
39 +++ b/drivers/usb/dwc_otg/dwc_otg_ifx.c
40 @@ -61,7 +61,10 @@ void dwc_otg_power_on (void)
42 writel(readl(DANUBE_PMU_PWDCR) | 0x41, DANUBE_PMU_PWDCR);
44 - writel(readl(DANUBE_CGU_IFCCR) | 0x30, DANUBE_CGU_IFCCR);
46 + writel(readl(DANUBE_CGU_IFCCR) & ~0x20, DANUBE_CGU_IFCCR);
48 + writel(readl(DANUBE_CGU_IFCCR) | 0x30, DANUBE_CGU_IFCCR);
50 writel(readl(DANUBE_PMU_PWDCR) & ~0x1, DANUBE_PMU_PWDCR);
51 writel(readl(DANUBE_PMU_PWDCR) & ~0x40, DANUBE_PMU_PWDCR);