aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVille Syrjälä <ville.syrjala@linux.intel.com>2016-05-11 15:44:44 -0400
committerVille Syrjälä <ville.syrjala@linux.intel.com>2016-05-13 14:31:08 -0400
commit4e5ca60fd35a2f042902e8047c1273aa79409977 (patch)
tree708f09cf02b1a8226fe62cce311cdc5e8bf7fffe
parentc44deb6caf074430944dd1a4879cf76217dae9d0 (diff)
drm/i915: Use ilk_max_pixel_rate() for BXT cdclk calculation
BXT uses the "pch" panel fitter configuration, so we can use ilk_max_pixel_rate() instead of intel_mode_max_pixclk() to compute the pipe pixel rate. ilk_max_pixel_rate() will account for the pipe scaler downscaling factor whereas intel_mode_max_pixclk() will not. I'm pretty sure the same limitation is there on GMCH platforms, but no one just bothered to implement the downscaling adjustment for them. Probably should just unify the panel fitter setup more across the platforms and use the exact same code on all platforms for this. But in the meantime, let's at least make BXT a bit more correct. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: http://patchwork.freedesktop.org/patch/msgid/1462995892-32416-6-git-send-email-ville.syrjala@linux.intel.com Reviewed-by: Jani Nikula <jani.nikula@intel.com>
-rw-r--r--drivers/gpu/drm/i915/intel_display.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
index be9b9e0386a8..c111ebcff36b 100644
--- a/drivers/gpu/drm/i915/intel_display.c
+++ b/drivers/gpu/drm/i915/intel_display.c
@@ -117,6 +117,7 @@ static void ironlake_pfit_disable(struct intel_crtc *crtc, bool force);
117static void ironlake_pfit_enable(struct intel_crtc *crtc); 117static void ironlake_pfit_enable(struct intel_crtc *crtc);
118static void intel_modeset_setup_hw_state(struct drm_device *dev); 118static void intel_modeset_setup_hw_state(struct drm_device *dev);
119static void intel_pre_disable_primary_noatomic(struct drm_crtc *crtc); 119static void intel_pre_disable_primary_noatomic(struct drm_crtc *crtc);
120static int ilk_max_pixel_rate(struct drm_atomic_state *state);
120 121
121struct intel_limit { 122struct intel_limit {
122 struct { 123 struct {
@@ -5963,8 +5964,7 @@ static int valleyview_modeset_calc_cdclk(struct drm_atomic_state *state)
5963 5964
5964static int broxton_modeset_calc_cdclk(struct drm_atomic_state *state) 5965static int broxton_modeset_calc_cdclk(struct drm_atomic_state *state)
5965{ 5966{
5966 struct drm_device *dev = state->dev; 5967 int max_pixclk = ilk_max_pixel_rate(state);
5967 int max_pixclk = intel_mode_max_pixclk(dev, state);
5968 struct intel_atomic_state *intel_state = 5968 struct intel_atomic_state *intel_state =
5969 to_intel_atomic_state(state); 5969 to_intel_atomic_state(state);
5970 5970