Home
last modified time | relevance | path

Searched hist:"87398174965 a99ea4f4990810f53daed225f4e48" (Results 1 – 1 of 1) sorted by relevance

/rk3399_rockchip-uboot/drivers/usb/dwc3/
H A Dgadget.c87398174965a99ea4f4990810f53daed225f4e48 Mon Feb 05 10:18:41 UTC 2024 William Wu <william.wu@rock-chips.com> usb: dwc3: gadget: Fix non-multiple maxpacket len for out req

If the length of OUT request isn't a multiple of
MaxPacketSize, the current code round up to multiple
of MaxPacketSize as the OUT transfer's buffer size,
but in the transfer complete handler, it still use
the original req length to calculate the actual length
of the transfer, and get a wrong actual length.

This patch use the transfer's buffer size to calculate
the actual length of the OUT request.

Fixes: 5433dc646a26 ("usb: dwc3: gadget: fix TRB buffer to multiple of MaxPacketSize")
Change-Id: I5132ee53044d16edd1bd26ccec3e4d98aba1d7c5
Signed-off-by: William Wu <william.wu@rock-chips.com>