aboutsummaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorGabor Juhos <juhosg@openwrt.org>2013-02-15 08:38:24 -0500
committerJohn Crispin <blogic@openwrt.org>2013-02-19 03:36:33 -0500
commit82c46840ae6bd8a147c59cd51f636d913989324a (patch)
tree1334eb1cb2476aeeae1945d012cab974160d8f91 /arch
parent0a5f3b1c9f20eb44142e3b37662de15c944f759d (diff)
MIPS: ath79: add USB controller registration code for the QCA955X SoCs
Register platfom devices for the built-in USB controllers of the SoCs. Cc: Rodriguez, Luis <rodrigue@qca.qualcomm.com> Cc: Giori, Kathy <kgiori@qca.qualcomm.com> Cc: QCA Linux Team <qca-linux-team@qca.qualcomm.com> Signed-off-by: Gabor Juhos <juhosg@openwrt.org> Patchwork: http://patchwork.linux-mips.org/patch/4952/ Signed-off-by: John Crispin <blogic@openwrt.org>
Diffstat (limited to 'arch')
-rw-r--r--arch/mips/ath79/dev-usb.c15
-rw-r--r--arch/mips/include/asm/mach-ath79/ar71xx_regs.h3
2 files changed, 18 insertions, 0 deletions
diff --git a/arch/mips/ath79/dev-usb.c b/arch/mips/ath79/dev-usb.c
index 02124d02cf6e..8227265bcc2d 100644
--- a/arch/mips/ath79/dev-usb.c
+++ b/arch/mips/ath79/dev-usb.c
@@ -208,6 +208,19 @@ static void __init ar934x_usb_setup(void)
208 &ath79_ehci_pdata_v2, sizeof(ath79_ehci_pdata_v2)); 208 &ath79_ehci_pdata_v2, sizeof(ath79_ehci_pdata_v2));
209} 209}
210 210
211static void __init qca955x_usb_setup(void)
212{
213 ath79_usb_register("ehci-platform", 0,
214 QCA955X_EHCI0_BASE, QCA955X_EHCI_SIZE,
215 ATH79_IP3_IRQ(0),
216 &ath79_ehci_pdata_v2, sizeof(ath79_ehci_pdata_v2));
217
218 ath79_usb_register("ehci-platform", 1,
219 QCA955X_EHCI1_BASE, QCA955X_EHCI_SIZE,
220 ATH79_IP3_IRQ(1),
221 &ath79_ehci_pdata_v2, sizeof(ath79_ehci_pdata_v2));
222}
223
211void __init ath79_register_usb(void) 224void __init ath79_register_usb(void)
212{ 225{
213 if (soc_is_ar71xx()) 226 if (soc_is_ar71xx())
@@ -222,6 +235,8 @@ void __init ath79_register_usb(void)
222 ar933x_usb_setup(); 235 ar933x_usb_setup();
223 else if (soc_is_ar934x()) 236 else if (soc_is_ar934x())
224 ar934x_usb_setup(); 237 ar934x_usb_setup();
238 else if (soc_is_qca955x())
239 qca955x_usb_setup();
225 else 240 else
226 BUG(); 241 BUG();
227} 242}
diff --git a/arch/mips/include/asm/mach-ath79/ar71xx_regs.h b/arch/mips/include/asm/mach-ath79/ar71xx_regs.h
index b7fa9d14d20f..4de183112917 100644
--- a/arch/mips/include/asm/mach-ath79/ar71xx_regs.h
+++ b/arch/mips/include/asm/mach-ath79/ar71xx_regs.h
@@ -109,6 +109,9 @@
109 109
110#define QCA955X_WMAC_BASE (AR71XX_APB_BASE + 0x00100000) 110#define QCA955X_WMAC_BASE (AR71XX_APB_BASE + 0x00100000)
111#define QCA955X_WMAC_SIZE 0x20000 111#define QCA955X_WMAC_SIZE 0x20000
112#define QCA955X_EHCI0_BASE 0x1b000000
113#define QCA955X_EHCI1_BASE 0x1b400000
114#define QCA955X_EHCI_SIZE 0x1000
112 115
113/* 116/*
114 * DDR_CTRL block 117 * DDR_CTRL block