* [PATCH 2/2] sh: add platform_device for USB function in board-sh7757lcr
@ 2011-09-26 8:43 Yoshihiro Shimoda
0 siblings, 0 replies; only message in thread
From: Yoshihiro Shimoda @ 2011-09-26 8:43 UTC (permalink / raw)
To: linux-sh
Signed-off-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>
---
This patch depends on the following patch:
- usb: r8a66597-udc: add support for SUDMAC
arch/sh/boards/board-sh7757lcr.c | 39 ++++++++++++++++++++++++++++++++++++++
1 files changed, 39 insertions(+), 0 deletions(-)
diff --git a/arch/sh/boards/board-sh7757lcr.c b/arch/sh/boards/board-sh7757lcr.c
index 8e6f9d7..dd2c8c6 100644
--- a/arch/sh/boards/board-sh7757lcr.c
+++ b/arch/sh/boards/board-sh7757lcr.c
@@ -18,6 +18,7 @@
#include <linux/mmc/host.h>
#include <linux/mmc/sh_mmcif.h>
#include <linux/mmc/sh_mobile_sdhi.h>
+#include <linux/usb/r8a66597.h>
#include <cpu/sh7757.h>
#include <asm/sh_eth.h>
#include <asm/heartbeat.h>
@@ -317,6 +318,43 @@ static struct platform_device riic3_device = {
},
};
+static struct r8a66597_platdata usb0_data = {
+ .on_chip = 1,
+ .buswait = 5,
+ .sudmac = 1,
+};
+
+static struct resource usb0_resources[] = {
+ [0] = {
+ .start = 0xfe450000,
+ .end = 0xfe4501ff,
+ .flags = IORESOURCE_MEM,
+ },
+ [1] = {
+ .start = 50,
+ .end = 50,
+ .flags = IORESOURCE_IRQ,
+ },
+ [2] = {
+ .name = "sudmac",
+ .start = 0xfe451000,
+ .end = 0xfe4517ff,
+ .flags = IORESOURCE_MEM,
+ },
+};
+
+static struct platform_device usb0_device = {
+ .name = "r8a66597_udc",
+ .id = 0,
+ .dev = {
+ .dma_mask = NULL,
+ .coherent_dma_mask = 0xffffffff,
+ .platform_data = &usb0_data,
+ },
+ .num_resources = ARRAY_SIZE(usb0_resources),
+ .resource = usb0_resources,
+};
+
static struct platform_device *sh7757lcr_devices[] __initdata = {
&heartbeat_device,
&sh7757_eth0_device,
@@ -327,6 +365,7 @@ static struct platform_device *sh7757lcr_devices[] __initdata = {
&sdhi_device,
&riic2_device,
&riic3_device,
+ &usb0_device,
};
static struct flash_platform_data spi_flash_data = {
--
1.7.1
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2011-09-26 8:43 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-09-26 8:43 [PATCH 2/2] sh: add platform_device for USB function in board-sh7757lcr Yoshihiro Shimoda
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.