drm/i915: Drop redundant NULL check
authorVille Syrjälä <ville.syrjala@linux.intel.com>
Thu, 7 Dec 2023 19:34:36 +0000 (21:34 +0200)
committerVille Syrjälä <ville.syrjala@linux.intel.com>
Fri, 8 Dec 2023 18:32:13 +0000 (20:32 +0200)
intel_bios_get_dsc_params() is only called from
gen11_dsi_dsc_compute_config() and it always passes a non-NULL
crtc_state in. Drop the redundant check.

Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20231207193441.20206-4-ville.syrjala@linux.intel.com
Reviewed-by: Jani Nikula <jani.nikula@intel.com>
drivers/gpu/drm/i915/display/intel_bios.c

index 3e7e96acb24abba979d9b1f91214e587b43023d2..aa169b0055e97da3738f6d4bc5b4481ab2e38696 100644 (file)
@@ -3475,8 +3475,7 @@ bool intel_bios_get_dsc_params(struct intel_encoder *encoder,
                        if (!devdata->dsc)
                                return false;
 
-                       if (crtc_state)
-                               fill_dsc(crtc_state, devdata->dsc, dsc_max_bpc);
+                       fill_dsc(crtc_state, devdata->dsc, dsc_max_bpc);
 
                        return true;
                }