usb: cdns3: gadget: calculate TD_SIZE based on TD
authorPeter Chen <peter.chen@nxp.com>
Tue, 3 Nov 2020 14:16:00 +0000 (22:16 +0800)
committerPeter Chen <peter.chen@nxp.com>
Mon, 16 Nov 2020 07:08:52 +0000 (15:08 +0800)
commit40252dd7cf7cad81c784c695c36bc475b518f0ea
treef0e9c549446dc317d83cedc17380bd137aa44a85
parent78e91588510919a0dc9bd48916e760c1ba5797d2
usb: cdns3: gadget: calculate TD_SIZE based on TD

The TRB entry TD_SIZE is the packet number for the TD (request) but not the
each TRB, so it only needs to be assigned for the first TRB during the TD,
and the value of it is for TD too.

Fixes: 7733f6c32e36 ("usb: cdns3: Add Cadence USB3 DRD Driver")
Signed-off-by: Peter Chen <peter.chen@nxp.com>
drivers/usb/cdns3/gadget.c