]> git.ipfire.org Git - thirdparty/kernel/stable.git/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:07:01 +0000 (17:07 +0000)
commit7932afa9bb6134f4f71a7cae604f689854b83310
tree1fa7b8b15e36035a1d72c3447ba4c92dc085e3d4
parent7cebc86481bf16049e266f6774d90f2fd4f8d5d2
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