2008-10-17 22:53:56 +00:00
|
|
|
From 2940d1996c86c4c4dd7a82214f846d0c0b707165 Mon Sep 17 00:00:00 2001
|
|
|
|
From: Maxime Bizon <mbizon@freebox.fr>
|
|
|
|
Date: Mon, 21 Jul 2008 18:24:42 +0200
|
|
|
|
Subject: [PATCH] [MIPS] BCM63XX: Add USB EHCI support.
|
|
|
|
|
|
|
|
Signed-off-by: Maxime Bizon <mbizon@freebox.fr>
|
|
|
|
---
|
|
|
|
arch/mips/bcm63xx/Kconfig | 2 +
|
|
|
|
arch/mips/bcm63xx/Makefile | 1 +
|
|
|
|
arch/mips/bcm63xx/dev-usb-ehci.c | 50 +++++++
|
|
|
|
drivers/usb/host/ehci-bcm63xx.c | 152 ++++++++++++++++++++
|
|
|
|
drivers/usb/host/ehci-hcd.c | 5 +
|
|
|
|
drivers/usb/host/ehci.h | 5 +
|
|
|
|
.../asm-mips/mach-bcm63xx/bcm63xx_dev_usb_ehci.h | 6 +
|
|
|
|
7 files changed, 221 insertions(+), 0 deletions(-)
|
|
|
|
create mode 100644 arch/mips/bcm63xx/dev-usb-ehci.c
|
|
|
|
create mode 100644 drivers/usb/host/ehci-bcm63xx.c
|
|
|
|
create mode 100644 include/asm-mips/mach-bcm63xx/bcm63xx_dev_usb_ehci.h
|
|
|
|
|
|
|
|
--- a/drivers/usb/host/ehci-hcd.c
|
|
|
|
+++ b/drivers/usb/host/ehci-hcd.c
|
2009-03-24 15:09:20 +00:00
|
|
|
@@ -1041,6 +1041,11 @@ MODULE_LICENSE ("GPL");
|
2008-10-17 22:53:56 +00:00
|
|
|
#define PLATFORM_DRIVER ixp4xx_ehci_driver
|
|
|
|
#endif
|
|
|
|
|
|
|
|
+#ifdef CONFIG_BCM63XX
|
|
|
|
+#include "ehci-bcm63xx.c"
|
|
|
|
+#define PLATFORM_DRIVER ehci_hcd_bcm63xx_driver
|
|
|
|
+#endif
|
|
|
|
+
|
|
|
|
#if !defined(PCI_DRIVER) && !defined(PLATFORM_DRIVER) && \
|
|
|
|
!defined(PS3_SYSTEM_BUS_DRIVER) && !defined(OF_PLATFORM_DRIVER)
|
|
|
|
#error "missing bus glue for ehci-hcd"
|
|
|
|
--- a/drivers/usb/host/ehci.h
|
|
|
|
+++ b/drivers/usb/host/ehci.h
|
2009-05-04 11:35:08 +00:00
|
|
|
@@ -764,6 +764,11 @@ ehci_port_speed(struct ehci_hcd *ehci, u
|
2008-10-17 22:53:56 +00:00
|
|
|
#define writel_be(val, addr) __raw_writel(val, (__force unsigned *)addr)
|
|
|
|
#endif
|
|
|
|
|
|
|
|
+#if defined(CONFIG_MIPS) && defined(CONFIG_BCM63XX)
|
|
|
|
+#define readl_be(addr) __raw_readl((__force unsigned *)addr)
|
|
|
|
+#define writel_be(val, addr) __raw_writel(val, (__force unsigned *)addr)
|
|
|
|
+#endif
|
|
|
|
+
|
|
|
|
static inline unsigned int ehci_readl(const struct ehci_hcd *ehci,
|
|
|
|
__u32 __iomem * regs)
|
|
|
|
{
|
2009-07-31 11:10:20 +00:00
|
|
|
--- a/drivers/usb/host/Kconfig
|
|
|
|
+++ b/drivers/usb/host/Kconfig
|
|
|
|
@@ -44,7 +44,7 @@ config USB_EHCI_HCD
|
2009-07-17 15:58:06 +00:00
|
|
|
|
|
|
|
config USB_EHCI_ROOT_HUB_TT
|
|
|
|
bool "Root Hub Transaction Translators"
|
|
|
|
- depends on USB_EHCI_HCD
|
|
|
|
+ depends on USB_EHCI_HCD && !BCM63XX
|
|
|
|
---help---
|
|
|
|
Some EHCI chips have vendor-specific extensions to integrate
|
|
|
|
transaction translators, so that no OHCI or UHCI companion
|