diff options
| author | Greg Kroah-Hartman <gregkh@suse.de> | 2008-04-11 17:00:09 -0700 |
|---|---|---|
| committer | Greg Kroah-Hartman <gregkh@suse.de> | 2008-04-11 17:00:09 -0700 |
| commit | 59aecebc5f62f9ae460ce89a475d8862029d724e (patch) | |
| tree | 00a3c96a102bf7cc71f03f3b41f587fcdb81929b /usb | |
| parent | 4bee607219f84a4eda440edd720479f8af8406c2 (diff) | |
| download | patches-59aecebc5f62f9ae460ce89a475d8862029d724e.tar.gz | |
build fixes...
Diffstat (limited to 'usb')
| -rw-r--r-- | usb/usb-host-fix-platform-driver-hotplug-coldplug.patch | 2 | ||||
| -rw-r--r-- | usb/usb-r8a66597-hcd-add-support-for-sh7366-usb-host.patch | 47 |
2 files changed, 18 insertions, 31 deletions
diff --git a/usb/usb-host-fix-platform-driver-hotplug-coldplug.patch b/usb/usb-host-fix-platform-driver-hotplug-coldplug.patch index eaf29e9191bdb9..1c0d5f597590d6 100644 --- a/usb/usb-host-fix-platform-driver-hotplug-coldplug.patch +++ b/usb/usb-host-fix-platform-driver-hotplug-coldplug.patch @@ -200,7 +200,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> #define DRIVER_VERSION "10 Apr 2008" -@@ -2338,6 +2339,7 @@ static struct platform_driver r8a66597_d +@@ -2323,6 +2324,7 @@ static struct platform_driver r8a66597_d .resume = r8a66597_resume, .driver = { .name = (char *) hcd_name, diff --git a/usb/usb-r8a66597-hcd-add-support-for-sh7366-usb-host.patch b/usb/usb-r8a66597-hcd-add-support-for-sh7366-usb-host.patch index a76187fc13f585..696a6b7ed84093 100644 --- a/usb/usb-r8a66597-hcd-add-support-for-sh7366-usb-host.patch +++ b/usb/usb-r8a66597-hcd-add-support-for-sh7366-usb-host.patch @@ -13,10 +13,10 @@ Signed-off-by: Yoshihiro Shimoda <shimoda.yoshihiro@renesas.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> --- - drivers/usb/host/Kconfig | 6 + - drivers/usb/host/r8a66597-hcd.c | 126 ++++++++++++++++++++++++++++------------ - drivers/usb/host/r8a66597.h | 45 ++++++++++++++ - 3 files changed, 142 insertions(+), 35 deletions(-) + drivers/usb/host/Kconfig | 6 ++ + drivers/usb/host/r8a66597-hcd.c | 115 +++++++++++++++++++++++++++------------- + drivers/usb/host/r8a66597.h | 45 +++++++++++++++ + 3 files changed, 129 insertions(+), 37 deletions(-) --- a/drivers/usb/host/Kconfig +++ b/drivers/usb/host/Kconfig @@ -105,7 +105,9 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> +static void r8a66597_disable_port(struct r8a66597 *r8a66597, int port) +{ + u16 val, tmp; -+ + +- r8a66597_bset(r8a66597, DCFM | DRPD, SYSCFG0); +- r8a66597_bset(r8a66597, DRPD, SYSCFG1); + r8a66597_write(r8a66597, 0, get_intenb_reg(port)); + r8a66597_write(r8a66597, 0, get_intsts_reg(port)); + @@ -115,9 +117,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> + tmp = r8a66597_read(r8a66597, SOFCFG) & EDGESTS; + udelay(640); + } while (tmp == EDGESTS); - -- r8a66597_bset(r8a66597, DCFM | DRPD, SYSCFG0); -- r8a66597_bset(r8a66597, DRPD, SYSCFG1); ++ + val = port ? DRPD : DCFM | DRPD; + r8a66597_bclr(r8a66597, val, get_syscfg_reg(port)); + r8a66597_bclr(r8a66597, HSE, get_syscfg_reg(port)); @@ -137,7 +137,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> r8a66597_bset(r8a66597, USBE, SYSCFG0); r8a66597_bset(r8a66597, BEMPE | NRDYE | BRDYE, INTENB0); -@@ -145,53 +208,45 @@ static int enable_controller(struct r8a6 +@@ -145,53 +208,30 @@ static int enable_controller(struct r8a6 r8a66597_bset(r8a66597, BRDY0, BRDYENB); r8a66597_bset(r8a66597, BEMP0, BEMPENB); @@ -173,45 +173,32 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> r8a66597_write(r8a66597, 0, INTSTS0); - r8a66597_write(r8a66597, 0, INTSTS1); - r8a66597_write(r8a66597, 0, INTSTS2); - +- - r8a66597_port_power(r8a66597, 0, 0); - r8a66597_port_power(r8a66597, 1, 0); -+ for (port = 0; port < R8A66597_MAX_ROOT_HUB; port++) -+ r8a66597_disable_port(r8a66597, port); - +- - do { - tmp = r8a66597_read(r8a66597, SOFCFG) & EDGESTS; - udelay(640); - } while (tmp == EDGESTS); -+ r8a66597_clock_disable(r8a66597); -+} - r8a66597_bclr(r8a66597, DCFM | DRPD, SYSCFG0); - r8a66597_bclr(r8a66597, DRPD, SYSCFG1); - r8a66597_bclr(r8a66597, HSE, SYSCFG0); - r8a66597_bclr(r8a66597, HSE, SYSCFG1); -+static int get_parent_r8a66597_address(struct r8a66597 *r8a66597, -+ struct usb_device *udev) -+{ -+ struct r8a66597_device *dev; ++ for (port = 0; port < R8A66597_MAX_ROOT_HUB; port++) ++ r8a66597_disable_port(r8a66597, port); - r8a66597_bclr(r8a66597, SCKE, SYSCFG0); - udelay(1); - r8a66597_bclr(r8a66597, PLLC, SYSCFG0); - r8a66597_bclr(r8a66597, XCKE, SYSCFG0); - r8a66597_bclr(r8a66597, USBE, SYSCFG0); -+ if (udev->parent && udev->parent->devnum != 1) -+ udev = udev->parent; -+ -+ dev = dev_get_drvdata(&udev->dev); -+ if (dev) -+ return dev->address; -+ else -+ return 0; ++ r8a66597_clock_disable(r8a66597); } static int get_parent_r8a66597_address(struct r8a66597 *r8a66597, -@@ -710,6 +765,7 @@ static void enable_r8a66597_pipe_dma(str +@@ -710,6 +750,7 @@ static void enable_r8a66597_pipe_dma(str struct r8a66597_pipe *pipe, struct urb *urb) { @@ -219,7 +206,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> int i; struct r8a66597_pipe_info *info = &pipe->info; -@@ -737,6 +793,7 @@ static void enable_r8a66597_pipe_dma(str +@@ -737,6 +778,7 @@ static void enable_r8a66597_pipe_dma(str break; } } @@ -227,7 +214,7 @@ Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> } /* this function must be called with interrupt disabled */ -@@ -1053,8 +1110,7 @@ static void prepare_status_packet(struct +@@ -1053,8 +1095,7 @@ static void prepare_status_packet(struct r8a66597_mdfy(r8a66597, ISEL, ISEL | CURPIPE, CFIFOSEL); r8a66597_reg_wait(r8a66597, CFIFOSEL, CURPIPE, 0); r8a66597_write(r8a66597, ~BEMP0, BEMPSTS); |
