public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [U-Boot] [PATCH 1/6] usb: ehci: mx6: Add support for i.MX6SL
@ 2014-06-16  0:46 Otavio Salvador
  2014-06-16  0:46 ` [U-Boot] [PATCH 2/6] imx: mx6sl: Extend USDHC SD2 pins to support 8-wire use Otavio Salvador
                   ` (7 more replies)
  0 siblings, 8 replies; 44+ messages in thread
From: Otavio Salvador @ 2014-06-16  0:46 UTC (permalink / raw)
  To: u-boot

The i.MX6SL has a different base address for the controller. This
patch adapts the driver to support the different base address for this
case.

Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
---

 drivers/usb/host/ehci-mx6.c | 10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)

diff --git a/drivers/usb/host/ehci-mx6.c b/drivers/usb/host/ehci-mx6.c
index c0a557b..5ba1c5e 100644
--- a/drivers/usb/host/ehci-mx6.c
+++ b/drivers/usb/host/ehci-mx6.c
@@ -53,6 +53,12 @@
 #define UCMD_RUN_STOP           (1 << 0) /* controller run/stop */
 #define UCMD_RESET		(1 << 1) /* controller reset */
 
+#ifdef CONFIG_MX6SL
+#define USB_BASE_ADDR		USBO2H_USB_BASE_ADDR
+#else
+#define USB_BASE_ADDR		USBOH3_USB_BASE_ADDR
+#endif
+
 static const unsigned phy_bases[] = {
 	USB_PHY0_BASE_ADDR,
 	USB_PHY1_BASE_ADDR,
@@ -174,7 +180,7 @@ struct usbnc_regs {
 
 static void usb_oc_config(int index)
 {
-	struct usbnc_regs *usbnc = (struct usbnc_regs *)(USBOH3_USB_BASE_ADDR +
+	struct usbnc_regs *usbnc = (struct usbnc_regs *)(USB_BASE_ADDR +
 			USB_OTHERREGS_OFFSET);
 	void __iomem *ctrl = (void __iomem *)(&usbnc->ctrl[index]);
 	u32 val;
@@ -207,7 +213,7 @@ int ehci_hcd_init(int index, enum usb_init_type init,
 		struct ehci_hccr **hccr, struct ehci_hcor **hcor)
 {
 	enum usb_init_type type;
-	struct usb_ehci *ehci = (struct usb_ehci *)(USBOH3_USB_BASE_ADDR +
+	struct usb_ehci *ehci = (struct usb_ehci *)(USB_BASE_ADDR +
 		(0x200 * index));
 
 	if (index > 3)
-- 
2.0.0

^ permalink raw reply related	[flat|nested] 44+ messages in thread
[parent not found: <mailman.3.1402912801.24865.u-boot@lists.denx.de>]

end of thread, other threads:[~2014-08-18 18:08 UTC | newest]

Thread overview: 44+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-06-16  0:46 [U-Boot] [PATCH 1/6] usb: ehci: mx6: Add support for i.MX6SL Otavio Salvador
2014-06-16  0:46 ` [U-Boot] [PATCH 2/6] imx: mx6sl: Extend USDHC SD2 pins to support 8-wire use Otavio Salvador
2014-06-16  0:46 ` [U-Boot] [PATCH 3/6] mmc: fsl_esdhc: Add CMD11 support to switch to 1.8V Otavio Salvador
2014-06-19 15:23   ` Andy Fleming
2014-06-16  0:46 ` [U-Boot] [PATCH 4/6] mmc: fsl_esdhc: Add support to force VSELECT set Otavio Salvador
2014-06-16  0:51   ` Marek Vasut
2014-06-16  1:22     ` Otavio Salvador
2014-06-16  1:27       ` Marek Vasut
2014-06-16  1:39         ` Otavio Salvador
2014-06-16  2:03           ` Marek Vasut
2014-06-16  2:24             ` Otavio Salvador
2014-06-16  7:03               ` Igor Grinberg
2014-06-16 11:48                 ` Otavio Salvador
2014-06-17  6:00                   ` Marek Vasut
2014-06-17  6:06                     ` Michael Trimarchi
2014-06-17 15:49                       ` Marek Vasut
2014-06-17 16:00                         ` Michael Trimarchi
2014-06-17  6:42                   ` Igor Grinberg
2014-06-17 15:11   ` Stefano Babic
2014-06-17 15:12     ` Otavio Salvador
2014-06-17 15:14       ` Michael Trimarchi
2014-06-17 15:19         ` Stefano Babic
2014-06-16  0:46 ` [U-Boot] [PATCH 5/6] Print ramdisk load address if it is in use Otavio Salvador
2014-06-16  4:38   ` Wolfgang Denk
2014-06-16 11:52     ` Otavio Salvador
2014-06-16  0:46 ` [U-Boot] [PATCH 6/6] warp: Add initial WaRP Board support Otavio Salvador
2014-06-16  0:54   ` Marek Vasut
2014-08-18 17:56   ` Fabio Estevam
2014-08-18 17:57     ` Fabio Estevam
2014-08-18 18:08       ` Otavio Salvador
2014-06-16  0:49 ` [U-Boot] [PATCH 1/6] usb: ehci: mx6: Add support for i.MX6SL Marek Vasut
2014-06-16  1:11   ` Otavio Salvador
2014-06-16  1:28     ` Marek Vasut
2014-06-16  7:05 ` Igor Grinberg
2014-06-16 11:51   ` Otavio Salvador
2014-06-17 14:56 ` Stefano Babic
2014-06-17 14:58   ` Otavio Salvador
     [not found] <mailman.3.1402912801.24865.u-boot@lists.denx.de>
2014-06-16 14:33 ` Nikolay Dimitrov
2014-06-16 14:53   ` Marek Vasut
2014-06-17 16:21     ` Nikolay Dimitrov
2014-06-17 16:36       ` Marek Vasut
2014-06-17  6:26   ` Igor Grinberg
2014-06-17 17:49     ` Nikolay Dimitrov
2014-06-19 12:56       ` Igor Grinberg

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox