Message ID | 1484031746-20874-1-git-send-email-vathsala.nagaraju@intel.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com> On Tue, 2017-01-10 at 12:32 +0530, vathsala nagaraju wrote: > PSR2 is restricted to work with panel resolutions upto 3200x2000, > move the check to intel_psr_match_conditions and fully block psr. > > Cc: Rodrigo Vivi <rodrigo.vivi@intel.com> > Cc: Jim Bride <jim.bride@linux.intel.com> > Suggested-by: Rodrigo Vivi <rodrigo.vivi@intel.com> > Signed-off-by: Vathsala Nagaraju <vathsala.nagaraju@intel.com> > --- > drivers/gpu/drm/i915/intel_psr.c | 15 ++++++++------- > 1 file changed, 8 insertions(+), 7 deletions(-) > > diff --git a/drivers/gpu/drm/i915/intel_psr.c b/drivers/gpu/drm/i915/intel_psr.c > index 6aca8ff..f2ca2a9 100644 > --- a/drivers/gpu/drm/i915/intel_psr.c > +++ b/drivers/gpu/drm/i915/intel_psr.c > @@ -387,6 +387,13 @@ static bool intel_psr_match_conditions(struct intel_dp *intel_dp) > return false; > } > > + /* PSR2 is restricted to work with panel resolutions upto 3200x2000 */ > + if (intel_crtc->config->pipe_src_w > 3200 || > + intel_crtc->config->pipe_src_h > 2000) { > + dev_priv->psr.psr2_support = false; > + return false; > + } > + > dev_priv->psr.source_ok = true; > return true; > } > @@ -425,7 +432,6 @@ void intel_psr_enable(struct intel_dp *intel_dp) > struct intel_digital_port *intel_dig_port = dp_to_dig_port(intel_dp); > struct drm_device *dev = intel_dig_port->base.base.dev; > struct drm_i915_private *dev_priv = to_i915(dev); > - struct intel_crtc *crtc = to_intel_crtc(intel_dig_port->base.base.crtc); > > if (!HAS_PSR(dev_priv)) { > DRM_DEBUG_KMS("PSR not supported on this platform\n"); > @@ -452,12 +458,7 @@ void intel_psr_enable(struct intel_dp *intel_dp) > hsw_psr_setup_vsc(intel_dp); > > if (dev_priv->psr.psr2_support) { > - /* PSR2 is restricted to work with panel resolutions upto 3200x2000 */ > - if (crtc->config->pipe_src_w > 3200 || > - crtc->config->pipe_src_h > 2000) > - dev_priv->psr.psr2_support = false; > - else > - skl_psr_setup_su_vsc(intel_dp); > + skl_psr_setup_su_vsc(intel_dp); > } > > /*
patch merged to dinq. thanks for the patch On Tue, Jan 10, 2017 at 12:48 PM Vivi, Rodrigo <rodrigo.vivi@intel.com> wrote: > Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com> > > On Tue, 2017-01-10 at 12:32 +0530, vathsala nagaraju wrote: > > PSR2 is restricted to work with panel resolutions upto 3200x2000, > > move the check to intel_psr_match_conditions and fully block psr. > > > > Cc: Rodrigo Vivi <rodrigo.vivi@intel.com> > > Cc: Jim Bride <jim.bride@linux.intel.com> > > Suggested-by: Rodrigo Vivi <rodrigo.vivi@intel.com> > > Signed-off-by: Vathsala Nagaraju <vathsala.nagaraju@intel.com> > > --- > > drivers/gpu/drm/i915/intel_psr.c | 15 ++++++++------- > > 1 file changed, 8 insertions(+), 7 deletions(-) > > > > diff --git a/drivers/gpu/drm/i915/intel_psr.c > b/drivers/gpu/drm/i915/intel_psr.c > > index 6aca8ff..f2ca2a9 100644 > > --- a/drivers/gpu/drm/i915/intel_psr.c > > +++ b/drivers/gpu/drm/i915/intel_psr.c > > @@ -387,6 +387,13 @@ static bool intel_psr_match_conditions(struct > intel_dp *intel_dp) > > return false; > > } > > > > + /* PSR2 is restricted to work with panel resolutions upto > 3200x2000 */ > > + if (intel_crtc->config->pipe_src_w > 3200 || > > + intel_crtc->config->pipe_src_h > 2000) { > > + dev_priv->psr.psr2_support = false; > > + return false; > > + } > > + > > dev_priv->psr.source_ok = true; > > return true; > > } > > @@ -425,7 +432,6 @@ void intel_psr_enable(struct intel_dp *intel_dp) > > struct intel_digital_port *intel_dig_port = > dp_to_dig_port(intel_dp); > > struct drm_device *dev = intel_dig_port->base.base.dev; > > struct drm_i915_private *dev_priv = to_i915(dev); > > - struct intel_crtc *crtc = > to_intel_crtc(intel_dig_port->base.base.crtc); > > > > if (!HAS_PSR(dev_priv)) { > > DRM_DEBUG_KMS("PSR not supported on this platform\n"); > > @@ -452,12 +458,7 @@ void intel_psr_enable(struct intel_dp *intel_dp) > > hsw_psr_setup_vsc(intel_dp); > > > > if (dev_priv->psr.psr2_support) { > > - /* PSR2 is restricted to work with panel > resolutions upto 3200x2000 */ > > - if (crtc->config->pipe_src_w > 3200 || > > - crtc->config->pipe_src_h > 2000) > > - dev_priv->psr.psr2_support = false; > > - else > > - skl_psr_setup_su_vsc(intel_dp); > > + skl_psr_setup_su_vsc(intel_dp); > > } > > > > /* > > _______________________________________________ > Intel-gfx mailing list > Intel-gfx@lists.freedesktop.org > https://lists.freedesktop.org/mailman/listinfo/intel-gfx >
diff --git a/drivers/gpu/drm/i915/intel_psr.c b/drivers/gpu/drm/i915/intel_psr.c index 6aca8ff..f2ca2a9 100644 --- a/drivers/gpu/drm/i915/intel_psr.c +++ b/drivers/gpu/drm/i915/intel_psr.c @@ -387,6 +387,13 @@ static bool intel_psr_match_conditions(struct intel_dp *intel_dp) return false; } + /* PSR2 is restricted to work with panel resolutions upto 3200x2000 */ + if (intel_crtc->config->pipe_src_w > 3200 || + intel_crtc->config->pipe_src_h > 2000) { + dev_priv->psr.psr2_support = false; + return false; + } + dev_priv->psr.source_ok = true; return true; } @@ -425,7 +432,6 @@ void intel_psr_enable(struct intel_dp *intel_dp) struct intel_digital_port *intel_dig_port = dp_to_dig_port(intel_dp); struct drm_device *dev = intel_dig_port->base.base.dev; struct drm_i915_private *dev_priv = to_i915(dev); - struct intel_crtc *crtc = to_intel_crtc(intel_dig_port->base.base.crtc); if (!HAS_PSR(dev_priv)) { DRM_DEBUG_KMS("PSR not supported on this platform\n"); @@ -452,12 +458,7 @@ void intel_psr_enable(struct intel_dp *intel_dp) hsw_psr_setup_vsc(intel_dp); if (dev_priv->psr.psr2_support) { - /* PSR2 is restricted to work with panel resolutions upto 3200x2000 */ - if (crtc->config->pipe_src_w > 3200 || - crtc->config->pipe_src_h > 2000) - dev_priv->psr.psr2_support = false; - else - skl_psr_setup_su_vsc(intel_dp); + skl_psr_setup_su_vsc(intel_dp); } /*
PSR2 is restricted to work with panel resolutions upto 3200x2000, move the check to intel_psr_match_conditions and fully block psr. Cc: Rodrigo Vivi <rodrigo.vivi@intel.com> Cc: Jim Bride <jim.bride@linux.intel.com> Suggested-by: Rodrigo Vivi <rodrigo.vivi@intel.com> Signed-off-by: Vathsala Nagaraju <vathsala.nagaraju@intel.com> --- drivers/gpu/drm/i915/intel_psr.c | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-)