aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/renesas_usbhs
diff options
context:
space:
mode:
authorThomas Gleixner <tglx@linutronix.de>2016-09-01 12:33:46 -0400
committerThomas Gleixner <tglx@linutronix.de>2016-09-01 12:33:46 -0400
commit0cb7bf61b1e9f05027de58c80f9b46a714d24e35 (patch)
tree41fb55cf62d07b425122f9a8b96412c0d8eb99c5 /drivers/usb/renesas_usbhs
parentaa877175e7a9982233ed8f10cb4bfddd78d82741 (diff)
parent3eab887a55424fc2c27553b7bfe32330df83f7b8 (diff)
Merge branch 'linus' into smp/hotplug
Apply upstream changes to avoid conflicts with pending patches.
Diffstat (limited to 'drivers/usb/renesas_usbhs')
-rw-r--r--drivers/usb/renesas_usbhs/common.c3
-rw-r--r--drivers/usb/renesas_usbhs/fifo.c4
-rw-r--r--drivers/usb/renesas_usbhs/mod_gadget.c7
3 files changed, 9 insertions, 5 deletions
diff --git a/drivers/usb/renesas_usbhs/common.c b/drivers/usb/renesas_usbhs/common.c
index 8fbbc2d32371..ac67bab9124c 100644
--- a/drivers/usb/renesas_usbhs/common.c
+++ b/drivers/usb/renesas_usbhs/common.c
@@ -514,7 +514,8 @@ static struct renesas_usbhs_platform_info *usbhs_parse_dt(struct device *dev)
514 if (gpio > 0) 514 if (gpio > 0)
515 dparam->enable_gpio = gpio; 515 dparam->enable_gpio = gpio;
516 516
517 if (dparam->type == USBHS_TYPE_RCAR_GEN2) 517 if (dparam->type == USBHS_TYPE_RCAR_GEN2 ||
518 dparam->type == USBHS_TYPE_RCAR_GEN3)
518 dparam->has_usb_dmac = 1; 519 dparam->has_usb_dmac = 1;
519 520
520 return info; 521 return info;
diff --git a/drivers/usb/renesas_usbhs/fifo.c b/drivers/usb/renesas_usbhs/fifo.c
index 280ed5ff021b..857e78337324 100644
--- a/drivers/usb/renesas_usbhs/fifo.c
+++ b/drivers/usb/renesas_usbhs/fifo.c
@@ -871,7 +871,7 @@ static int usbhsf_dma_prepare_push(struct usbhs_pkt *pkt, int *is_done)
871 871
872 /* use PIO if packet is less than pio_dma_border or pipe is DCP */ 872 /* use PIO if packet is less than pio_dma_border or pipe is DCP */
873 if ((len < usbhs_get_dparam(priv, pio_dma_border)) || 873 if ((len < usbhs_get_dparam(priv, pio_dma_border)) ||
874 usbhs_pipe_is_dcp(pipe)) 874 usbhs_pipe_type_is(pipe, USB_ENDPOINT_XFER_ISOC))
875 goto usbhsf_pio_prepare_push; 875 goto usbhsf_pio_prepare_push;
876 876
877 /* check data length if this driver don't use USB-DMAC */ 877 /* check data length if this driver don't use USB-DMAC */
@@ -976,7 +976,7 @@ static int usbhsf_dma_prepare_pop_with_usb_dmac(struct usbhs_pkt *pkt,
976 976
977 /* use PIO if packet is less than pio_dma_border or pipe is DCP */ 977 /* use PIO if packet is less than pio_dma_border or pipe is DCP */
978 if ((pkt->length < usbhs_get_dparam(priv, pio_dma_border)) || 978 if ((pkt->length < usbhs_get_dparam(priv, pio_dma_border)) ||
979 usbhs_pipe_is_dcp(pipe)) 979 usbhs_pipe_type_is(pipe, USB_ENDPOINT_XFER_ISOC))
980 goto usbhsf_pio_prepare_pop; 980 goto usbhsf_pio_prepare_pop;
981 981
982 fifo = usbhsf_get_dma_fifo(priv, pkt); 982 fifo = usbhsf_get_dma_fifo(priv, pkt);
diff --git a/drivers/usb/renesas_usbhs/mod_gadget.c b/drivers/usb/renesas_usbhs/mod_gadget.c
index 50f3363cc382..92bc83b92d10 100644
--- a/drivers/usb/renesas_usbhs/mod_gadget.c
+++ b/drivers/usb/renesas_usbhs/mod_gadget.c
@@ -617,10 +617,13 @@ static int usbhsg_ep_enable(struct usb_ep *ep,
617 * use dmaengine if possible. 617 * use dmaengine if possible.
618 * It will use pio handler if impossible. 618 * It will use pio handler if impossible.
619 */ 619 */
620 if (usb_endpoint_dir_in(desc)) 620 if (usb_endpoint_dir_in(desc)) {
621 pipe->handler = &usbhs_fifo_dma_push_handler; 621 pipe->handler = &usbhs_fifo_dma_push_handler;
622 else 622 } else {
623 pipe->handler = &usbhs_fifo_dma_pop_handler; 623 pipe->handler = &usbhs_fifo_dma_pop_handler;
624 usbhs_xxxsts_clear(priv, BRDYSTS,
625 usbhs_pipe_number(pipe));
626 }
624 627
625 ret = 0; 628 ret = 0;
626 } 629 }