Re: [PATCH 1/7] drm/i915/dp: Use HAS_DSC macro in intel_dp_dsc_max_src_input_bpc

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




On 10/17/2024 5:43 PM, Imre Deak wrote:
On Thu, Oct 03, 2024 at 04:13:37PM +0530, Ankit Nautiyal wrote:
Use HAS_DSC macro to take into account platforms for which DSC is fused.

Signed-off-by: Ankit Nautiyal <ankit.k.nautiyal@xxxxxxxxx>
---
  drivers/gpu/drm/i915/display/intel_dp.c | 3 +++
  1 file changed, 3 insertions(+)

diff --git a/drivers/gpu/drm/i915/display/intel_dp.c b/drivers/gpu/drm/i915/display/intel_dp.c
index c4fdae5097ec..c47748905506 100644
--- a/drivers/gpu/drm/i915/display/intel_dp.c
+++ b/drivers/gpu/drm/i915/display/intel_dp.c
@@ -1766,6 +1766,9 @@ intel_dp_compute_link_config_wide(struct intel_dp *intel_dp,
  static
  u8 intel_dp_dsc_max_src_input_bpc(struct drm_i915_private *i915)
  {
+	if (!HAS_DSC(i915))
This is checked already earlier via intel_dp_has_dsc(), couldn't we rely
on that instead of checking it in these lower level functions?

Sorry for replying late to this.

You are right currently we already check this long before calling this function.

However I am intending to use this in intel_dp_compute_config_link_bpp_limits which is earlier than the check for DSC, for that perhaps need to add a check before computing link bpp limits for DSC.

In any case we can avoid the HAS_DSC() check here and in corresponding min helper too.

Regards,

Ankit


+		return 0;
+
  	/* Max DSC Input BPC for ICL is 10 and for TGL+ is 12 */
  	if (DISPLAY_VER(i915) >= 12)
  		return 12;
--
2.45.2




[Index of Archives]     [AMD Graphics]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux