From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from metis.ext.pengutronix.de ([2001:6f8:1178:4:290:27ff:fe1d:cc33]) by merlin.infradead.org with esmtps (Exim 4.76 #1 (Red Hat Linux)) id 1TjC9R-0001nc-82 for barebox@lists.infradead.org; Thu, 13 Dec 2012 17:00:51 +0000 From: Sascha Hauer Date: Thu, 13 Dec 2012 18:00:39 +0100 Message-Id: <1355418044-27452-5-git-send-email-s.hauer@pengutronix.de> In-Reply-To: <1355418044-27452-1-git-send-email-s.hauer@pengutronix.de> References: <1355418044-27452-1-git-send-email-s.hauer@pengutronix.de> List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: barebox-bounces@lists.infradead.org Errors-To: barebox-bounces+u.kleine-koenig=pengutronix.de@lists.infradead.org Subject: [PATCH 4/9] ARM i.MX51: Add USB device functions To: barebox@lists.infradead.org Signed-off-by: Sascha Hauer --- arch/arm/mach-imx/imx51.c | 1 + arch/arm/mach-imx/include/mach/devices-imx51.h | 15 +++++++++++++++ 2 files changed, 16 insertions(+) diff --git a/arch/arm/mach-imx/imx51.c b/arch/arm/mach-imx/imx51.c index a62daf8..cffcca3 100644 --- a/arch/arm/mach-imx/imx51.c +++ b/arch/arm/mach-imx/imx51.c @@ -70,6 +70,7 @@ static int imx51_init(void) add_generic_device("imx31-gpio", 3, NULL, MX51_GPIO4_BASE_ADDR, 0x1000, IORESOURCE_MEM, NULL); add_generic_device("imx21-wdt", 0, NULL, MX51_WDOG_BASE_ADDR, 0x1000, IORESOURCE_MEM, NULL); add_generic_device("imx51-esdctl", 0, NULL, MX51_ESDCTL_BASE_ADDR, 0x1000, IORESOURCE_MEM, NULL); + add_generic_device("imx51-usb-misc", 0, NULL, MX51_OTG_BASE_ADDR + 0x800, 0x100, IORESOURCE_MEM, NULL); return 0; } diff --git a/arch/arm/mach-imx/include/mach/devices-imx51.h b/arch/arm/mach-imx/include/mach/devices-imx51.h index 95497fa..ec8467a 100644 --- a/arch/arm/mach-imx/include/mach/devices-imx51.h +++ b/arch/arm/mach-imx/include/mach/devices-imx51.h @@ -98,3 +98,18 @@ static inline struct device_d *imx51_add_pata(void) { return imx_add_pata((void *)MX51_ATA_BASE_ADDR); } + +static inline struct device_d *imx51_add_usbotg(void *pdata) +{ + return imx_add_usb((void *)MX51_OTG_BASE_ADDR, 0, pdata); +} + +static inline struct device_d *imx51_add_usbh1(void *pdata) +{ + return imx_add_usb((void *)MX51_OTG_BASE_ADDR + 0x200, 1, pdata); +} + +static inline struct device_d *imx51_add_usbh2(void *pdata) +{ + return imx_add_usb((void *)MX51_OTG_BASE_ADDR + 0x400, 2, pdata); +} -- 1.7.10.4 _______________________________________________ barebox mailing list barebox@lists.infradead.org http://lists.infradead.org/mailman/listinfo/barebox