]> git.baikalelectronics.ru Git - kernel.git/commit
usb: dwc2: gadget: fix zero length packet transfers
authorMian Yousaf Kaukab <yousaf.kaukab@intel.com>
Fri, 9 Jan 2015 12:38:59 +0000 (13:38 +0100)
committerFelipe Balbi <balbi@ti.com>
Mon, 12 Jan 2015 21:34:08 +0000 (15:34 -0600)
commitcf787cbd114ee32da22f35a6c176c8aeb711375b
tree9424399d8b8c67f8394bc00c59f4828e167d569f
parent3c296e88018b1353a865642712c554f64339aba6
usb: dwc2: gadget: fix zero length packet transfers

According to programming guide, zero length packet should be
programmed on its own and should not be counted in DIEPTSIZ.PktCnt
with other packets.

For ep0, this is the zlp for DATA IN stage (if required) and not for
the STATUS stage.

Tested-by: Robert Baldyga <r.baldyga@samsung.com>
Acked-by: Paul Zimmerman <paulz@synopsys.com>
Signed-off-by: Gregory Herrero <gregory.herrero@intel.com>
Signed-off-by: Mian Yousaf Kaukab <yousaf.kaukab@intel.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
drivers/usb/dwc2/gadget.c