aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/renesas_usbhs
diff options
context:
space:
mode:
authorKuninori Morimoto <kuninori.morimoto.gx@renesas.com>2011-11-24 20:28:17 -0500
committerFelipe Balbi <balbi@ti.com>2011-12-12 04:45:18 -0500
commit25fa70795bf11ef6f5b147f0b231a43880ba96ca (patch)
treee2231d479fc4659e3450a4d6d355258e3c3d1f21 /drivers/usb/renesas_usbhs
parent17f7f76940214af91bfefcf9a2ca156701d905e6 (diff)
usb: renesas_usbhs: send packet in necessary timing.
Current renesas_usbhs driver always tries to send packet in end of recip handler. But it breaks chapter 9 EndpointHalt test. This patch fixup this issue. Signed-off-by: Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: Felipe Balbi <balbi@ti.com>
Diffstat (limited to 'drivers/usb/renesas_usbhs')
-rw-r--r--drivers/usb/renesas_usbhs/mod_gadget.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/drivers/usb/renesas_usbhs/mod_gadget.c b/drivers/usb/renesas_usbhs/mod_gadget.c
index 812960ba95e1..16484060a24c 100644
--- a/drivers/usb/renesas_usbhs/mod_gadget.c
+++ b/drivers/usb/renesas_usbhs/mod_gadget.c
@@ -271,6 +271,8 @@ static int usbhsg_recip_handler_std_clear_endpoint(struct usbhs_priv *priv,
271 271
272 usbhsg_recip_handler_std_control_done(priv, uep, ctrl); 272 usbhsg_recip_handler_std_control_done(priv, uep, ctrl);
273 273
274 usbhs_pkt_start(pipe);
275
274 return 0; 276 return 0;
275} 277}
276 278
@@ -424,8 +426,7 @@ static int usbhsg_recip_run_handle(struct usbhs_priv *priv,
424 pipe = usbhsg_uep_to_pipe(uep); 426 pipe = usbhsg_uep_to_pipe(uep);
425 if (!pipe) { 427 if (!pipe) {
426 dev_err(dev, "wrong recip request\n"); 428 dev_err(dev, "wrong recip request\n");
427 ret = -EINVAL; 429 return -EINVAL;
428 goto usbhsg_recip_run_handle_end;
429 } 430 }
430 431
431 switch (recip) { 432 switch (recip) {
@@ -452,9 +453,6 @@ static int usbhsg_recip_run_handle(struct usbhs_priv *priv,
452 ret = func(priv, uep, ctrl); 453 ret = func(priv, uep, ctrl);
453 } 454 }
454 455
455usbhsg_recip_run_handle_end:
456 usbhs_pkt_start(pipe);
457
458 return ret; 456 return ret;
459} 457}
460 458