[Intel-gfx] [RFC 7/7] drm/i915: Allow vdsc functions to be called without encoder.
Manasi Navare
manasi.d.navare at intel.com
Wed Jul 10 22:35:51 UTC 2019
On Tue, Jul 02, 2019 at 09:42:05PM +0200, Maarten Lankhorst wrote:
> This can be useful when calling the vdsc enable functions
> directly without encoder.
Would this be the case on the slave pipe where we need to enable DSC but there
is no transcoder enabled for that pipe?
Manasi
>
> Signed-off-by: Maarten Lankhorst <maarten.lankhorst at linux.intel.com>
> ---
> drivers/gpu/drm/i915/display/intel_vdsc.c | 8 +++++---
> 1 file changed, 5 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/gpu/drm/i915/display/intel_vdsc.c b/drivers/gpu/drm/i915/display/intel_vdsc.c
> index 419a77723894..f009524ab735 100644
> --- a/drivers/gpu/drm/i915/display/intel_vdsc.c
> +++ b/drivers/gpu/drm/i915/display/intel_vdsc.c
> @@ -897,7 +897,7 @@ void intel_dsc_enable(struct intel_encoder *encoder,
> const struct intel_crtc_state *crtc_state)
> {
> struct intel_crtc *crtc = to_intel_crtc(crtc_state->uapi.crtc);
> - struct drm_i915_private *dev_priv = to_i915(encoder->base.dev);
> + struct drm_i915_private *dev_priv = to_i915(crtc->base.dev);
> enum pipe pipe = crtc->pipe;
> i915_reg_t dss_ctl1_reg, dss_ctl2_reg;
> u32 dss_ctl1_val = 0;
> @@ -910,9 +910,11 @@ void intel_dsc_enable(struct intel_encoder *encoder,
> intel_display_power_get(dev_priv,
> intel_dsc_power_domain(crtc_state));
>
> - intel_configure_pps_for_dsc_encoder(encoder, crtc_state);
> + if (encoder) {
> + intel_configure_pps_for_dsc_encoder(encoder, crtc_state);
>
> - intel_dp_write_dsc_pps_sdp(encoder, crtc_state);
> + intel_dp_write_dsc_pps_sdp(encoder, crtc_state);
> + }
>
> if (crtc_state->cpu_transcoder == TRANSCODER_EDP) {
> dss_ctl1_reg = DSS_CTL1;
> --
> 2.20.1
>
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/intel-gfx
More information about the Intel-gfx
mailing list