]> git.ipfire.org Git - thirdparty/linux.git/commit
drm/i915/dp_tunnel: Simplify detection of link BW change
authorImre Deak <imre.deak@intel.com>
Thu, 19 Feb 2026 18:28:20 +0000 (20:28 +0200)
committerImre Deak <imre.deak@intel.com>
Wed, 25 Feb 2026 13:30:11 +0000 (15:30 +0200)
commit02feab823760cf08272b12901776e117616f1047
treeed6497a84584b8f2075a10b364c8c34da27a8cb8
parentafe3f74716235f9c137e9850ee0027391b46b570
drm/i915/dp_tunnel: Simplify detection of link BW change

update_tunnel_state() checks whether a tunnel state change (e.g.
available tunnel bandwidth) affects the list of valid modes for the
sink connected through the tunnel. If so, its caller sends a hotplug
event so userspace can re-enumerate the modes.

A change in tunnel bandwidth does not affect the mode list if the
bandwidth was above the sink's DPRX bandwidth both before and after the
update, since in that case the effective bandwidth remains limited by
the DPRX.

As get_current_link_bw() via intel_dp_max_link_data_rate() already
returns bandwidth values clamped to the DPRX limit, the condition for
detecting a mode list change can be simplified to:

    old_bw != new_bw

Remove the explicit checks for whether the bandwidth was below the
maximum DPRX bandwidth before and after the update, and rely on the
clamped bandwidth values instead.

Reviewed-by: Arun R Murthy <arun.r.murthy@intel.com>
Signed-off-by: Imre Deak <imre.deak@intel.com>
Link: https://patch.msgid.link/20260219182823.926702-3-imre.deak@intel.com
drivers/gpu/drm/i915/display/intel_dp_tunnel.c