[PATCH 09/14] drm/i915/dp: Check if mode can be supported with dsc compressed bpp
Ankit Nautiyal
ankit.k.nautiyal at intel.com
Mon Feb 13 11:08:47 UTC 2023
Use compressed bpp to calculate mode_rate during dp_mode_valid.
Check if this can be supported with max lane count and link rate
combination.
Signed-off-by: Ankit Nautiyal <ankit.k.nautiyal at intel.com>
---
drivers/gpu/drm/i915/display/intel_dp.c | 9 ++++++---
1 file changed, 6 insertions(+), 3 deletions(-)
diff --git a/drivers/gpu/drm/i915/display/intel_dp.c b/drivers/gpu/drm/i915/display/intel_dp.c
index a721ae5de858..b83dc32bdc7c 100644
--- a/drivers/gpu/drm/i915/display/intel_dp.c
+++ b/drivers/gpu/drm/i915/display/intel_dp.c
@@ -1134,8 +1134,6 @@ intel_dp_mode_valid(struct drm_connector *_connector,
max_lanes = intel_dp_max_lane_count(intel_dp);
max_rate = intel_dp_max_data_rate(max_link_clock, max_lanes);
- mode_rate = intel_dp_link_required(target_clock,
- intel_dp_mode_min_output_bpp(connector, mode));
if (HAS_DSC(dev_priv) &&
drm_dp_sink_supports_dsc(intel_dp->dsc_dpcd)) {
@@ -1191,7 +1189,12 @@ intel_dp_mode_valid(struct drm_connector *_connector,
if (DISPLAY_VER(dev_priv) < 13 && bigjoiner && !dsc)
return MODE_CLOCK_HIGH;
- if (mode_rate > max_rate && !dsc)
+ if (dsc)
+ mode_rate = intel_dp_link_required(target_clock, dsc_max_output_bpp);
+ else
+ mode_rate = intel_dp_link_required(target_clock,
+ intel_dp_mode_min_output_bpp(connector, mode));
+ if (mode_rate > max_rate)
return MODE_CLOCK_HIGH;
status = intel_dp_mode_valid_downstream(connector, mode, target_clock);
--
2.25.1
More information about the Intel-gfx-trybot
mailing list