]> git.hungrycats.org Git - linux/commit
usb: dwc3: core: configure TX/RX threshold for DWC3_IP
authorStanley Chang <stanley_chang@realtek.com>
Tue, 12 Sep 2023 04:19:02 +0000 (12:19 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 28 Nov 2023 17:14:49 +0000 (17:14 +0000)
commit5a6afa6a84270b1c612a3bc7a953cb5a65db49e8
treed3a9a1a579e604ec3bb84ab17af46fb574cd968b
parent11fbc83578202b60f561da67c98d79bd1aba669c
usb: dwc3: core: configure TX/RX threshold for DWC3_IP

[ Upstream commit e72fc8d6a12af7ae8dd1b52cf68ed68569d29f80 ]

In Synopsys's dwc3 data book:
To avoid underrun and overrun during the burst, in a high-latency bus
system (like USB), threshold and burst size control is provided through
GTXTHRCFG and GRXTHRCFG registers.

In Realtek DHC SoC, DWC3 USB 3.0 uses AHB system bus. When dwc3 is
connected with USB 2.5G Ethernet, there will be overrun problem.
Therefore, setting TX/RX thresholds can avoid this issue.

Signed-off-by: Stanley Chang <stanley_chang@realtek.com>
Acked-by: Thinh Nguyen <Thinh.Nguyen@synopsys.com>
Link: https://lore.kernel.org/r/20230912041904.30721-1-stanley_chang@realtek.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/usb/dwc3/core.c
drivers/usb/dwc3/core.h