aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorMika Westerberg <mika.westerberg@linux.intel.com>2024-08-28 15:07:54 +0300
committerMika Westerberg <mika.westerberg@linux.intel.com>2025-01-03 11:50:08 +0200
commit58b4af9c43ca6b0f2508ff0537ea46438359b970 (patch)
treec2d83c0a0c231d5f456c5bf6c9adee978801a9b7
parentthunderbolt: Debug log an invalid config space reply just once (diff)
downloadwireguard-linux-58b4af9c43ca6b0f2508ff0537ea46438359b970.tar.xz
wireguard-linux-58b4af9c43ca6b0f2508ff0537ea46438359b970.zip
thunderbolt: Increase DPRX capabilities read timeout
Some graphics drivers such as i915 support runtime power management and if there is nothing connected at the moment they will runtime suspend to save power. At least i915 is polling for new connections every 10 seconds if the hardware does support sending PME. To allow i915 and other graphics from detect the just established DisplayPort tunnel allow the DPRX capabilities read to take up to 12 seconds. Signed-off-by: Mika Westerberg <mika.westerberg@linux.intel.com>
-rw-r--r--drivers/thunderbolt/tunnel.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/drivers/thunderbolt/tunnel.c b/drivers/thunderbolt/tunnel.c
index 41cf6378ad25..f9e75c221fef 100644
--- a/drivers/thunderbolt/tunnel.c
+++ b/drivers/thunderbolt/tunnel.c
@@ -1186,9 +1186,12 @@ static int tb_dp_consumed_bandwidth(struct tb_tunnel *tunnel, int *consumed_up,
* return that bandwidth (it may be smaller than the
* reduced one). According to VESA spec, the DPRX
* negotiation shall compete in 5 seconds after tunnel
- * established. We give it 100ms extra just in case.
+ * established. Since at least i915 can runtime suspend
+ * if there is nothing connected, and that it polls any
+ * new connections every 10 seconds, we use 12 seconds
+ * here.
*/
- ret = tb_dp_wait_dprx(tunnel, 5100);
+ ret = tb_dp_wait_dprx(tunnel, 12000);
if (ret)
return ret;
ret = tb_dp_read_cap(tunnel, DP_COMMON_CAP, &rate, &lanes);