[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1453352672-27890-5-git-send-email-dianders@chromium.org>
Date: Wed, 20 Jan 2016 21:04:15 -0800
From: Douglas Anderson <dianders@...omium.org>
To: John Youn <John.Youn@...opsys.com>, balbi@...com,
kever.yang@...k-chips.com
Cc: Heiko Stübner <heiko@...ech.de>,
linux-rockchip@...ts.infradead.org,
Julius Werner <jwerner@...omium.org>,
gregory.herrero@...el.com, yousaf.kaukab@...el.com,
dinguyen@...nsource.altera.com, stern@...land.harvard.edu,
ming.lei@...onical.com, Douglas Anderson <dianders@...omium.org>,
johnyoun@...opsys.com, gregkh@...uxfoundation.org,
linux-usb@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: [PATCH v4 04/21] usb: dwc2: host: Set host_perio_tx_fifo_size to 304 for rk3066
Looking at rk3288, there are two dwc2 ports. One has 960
total_fifo_size and the other 972.
We're currently assigning 528 + 128 + 256 = 912. That means we're
wasting 48 words on one port and 60 words on the other. Since we have
one settings block for both ports, let's just eat the 48 words that we
know we have and assign them to what's probably the most
latency-senstive part of the system: periodic transfers.
Presumably other rk3288 parts using the rk3066 settings also have these
extra 48 words as well.
Note: ideally we'd adjust dwc2_calculate_dynamic_fifo() to handle this
more dynamically, but until that's done hardcoding things here seems OK.
NOTE: no known use cases are improved by this patch, but in my stressful
USB tests I certainly see my periodic FIFO filling up both before and
after this change. Presumably there are some USB configurations where
the periodic FIFO would have been filled before where it no longer is.
Signed-off-by: Douglas Anderson <dianders@...omium.org>
---
Changes in v4:
- Set host_perio_tx_fifo_size to 304 for rk3066 new for v4.
Changes in v3: None
Changes in v2: None
drivers/usb/dwc2/platform.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/usb/dwc2/platform.c b/drivers/usb/dwc2/platform.c
index b6d7666e715c..afdcdeee266d 100644
--- a/drivers/usb/dwc2/platform.c
+++ b/drivers/usb/dwc2/platform.c
@@ -128,7 +128,7 @@ static const struct dwc2_core_params params_rk3066 = {
.en_multiple_tx_fifo = -1,
.host_rx_fifo_size = 528, /* 528 DWORDs */
.host_nperio_tx_fifo_size = 128, /* 128 DWORDs */
- .host_perio_tx_fifo_size = 256, /* 256 DWORDs */
+ .host_perio_tx_fifo_size = 304, /* 304 DWORDs */
.max_transfer_size = -1,
.max_packet_count = -1,
.host_channels = -1,
--
2.7.0.rc3.207.g0ac5344
Powered by blists - more mailing lists