diff options
author | Pratyush Anand <pratyush.anand@st.com> | 2013-01-14 15:59:36 +0530 |
---|---|---|
committer | Felipe Balbi <balbi@ti.com> | 2013-01-18 14:31:07 +0200 |
commit | 1877d6c9a57802d50a059cf2dacdba10168cece7 (patch) | |
tree | 4f209934ff77db0aaab54be2b84b62c19dfe12e5 /drivers/usb/dwc3 | |
parent | 915e202aeeb59e272992a6364c910aaef3073544 (diff) | |
download | linux-1877d6c9a57802d50a059cf2dacdba10168cece7.tar.bz2 |
usb: dwc3: gadget: no need to pass params in case of UPDATE_TRANSFER
UPDATE_TRANSFER does not need any parameters. So, no need to prepare it.
Signed-off-by: Pratyush Anand <pratyush.anand@st.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
Diffstat (limited to 'drivers/usb/dwc3')
-rw-r--r-- | drivers/usb/dwc3/gadget.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/drivers/usb/dwc3/gadget.c b/drivers/usb/dwc3/gadget.c index da8d57cb00e8..686c31c3d87c 100644 --- a/drivers/usb/dwc3/gadget.c +++ b/drivers/usb/dwc3/gadget.c @@ -974,13 +974,14 @@ static int __dwc3_gadget_kick_transfer(struct dwc3_ep *dep, u16 cmd_param, } memset(¶ms, 0, sizeof(params)); - params.param0 = upper_32_bits(req->trb_dma); - params.param1 = lower_32_bits(req->trb_dma); - if (start_new) + if (start_new) { + params.param0 = upper_32_bits(req->trb_dma); + params.param1 = lower_32_bits(req->trb_dma); cmd = DWC3_DEPCMD_STARTTRANSFER; - else + } else { cmd = DWC3_DEPCMD_UPDATETRANSFER; + } cmd |= DWC3_DEPCMD_PARAM(cmd_param); ret = dwc3_send_gadget_ep_cmd(dwc, dep->number, cmd, ¶ms); |