usb: xhci: Limit transfer length of a single TD
authorDongwoo Lee <dwoo08.lee@samsung.com>
Mon, 7 Nov 2016 05:34:15 +0000 (14:34 +0900)
committerMarek Szyprowski <m.szyprowski@samsung.com>
Mon, 15 Nov 2021 10:19:26 +0000 (11:19 +0100)
commite6abdf5a6f8f5ac57c8dae509cb5b0d320ea906b
treee7cd6ba179dc794a628b3cdcb4ffb8e31c7e9fea
parent84cec267d0e596e08910e31793739c42a793c0c7
usb: xhci: Limit transfer length of a single TD

This is workaround solution for timed out error and babble error while
transfering data exceeding 0x3F01FF bytes on xhci host. Actually, this
size equals to value that the maximum number of TRBs per TD times the
maximum size of transfer buffer on TRB. Thus, huge transfer request is
splitted in order to limit the size of data in a single TD.

Even though the single I/O request is splitted into multiple requests,
the transfer speed has affected insignificantly: 22.6 --> 22.3 MiB/s.

Change-Id: I85a17910587b70807f075dd40634a0da817cea2f
Signed-off-by: Dongwoo Lee <dwoo08.lee@samsung.com>
drivers/usb/host/xhci.c