Message ID | 1394209951-9963-4-git-send-email-ville.syrjala@linux.intel.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
2014-03-07 13:32 GMT-03:00 <ville.syrjala@linux.intel.com>: > From: Ville Syrjälä <ville.syrjala@linux.intel.com> > > Even though the inactive pipes should have their watermarks set to all 0 > with enable=true, we can possibly shave off a few cycles by completely > skipping the merge procedure for inactive pipes. > > Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by: Paulo Zanoni <paulo.r.zanoni@Intel.com> > --- > drivers/gpu/drm/i915/intel_pm.c | 7 +++++-- > 1 file changed, 5 insertions(+), 2 deletions(-) > > diff --git a/drivers/gpu/drm/i915/intel_pm.c b/drivers/gpu/drm/i915/intel_pm.c > index e0d1c8b..e13937f 100644 > --- a/drivers/gpu/drm/i915/intel_pm.c > +++ b/drivers/gpu/drm/i915/intel_pm.c > @@ -2206,8 +2206,11 @@ static void ilk_merge_wm_level(struct drm_device *dev, > const struct intel_crtc *intel_crtc; > > list_for_each_entry(intel_crtc, &dev->mode_config.crtc_list, base.head) { > - const struct intel_wm_level *wm = > - &intel_crtc->wm.active.wm[level]; > + const struct intel_pipe_wm *active = &intel_crtc->wm.active; > + const struct intel_wm_level *wm = &active->wm[level]; > + > + if (!active->pipe_enabled) > + continue; > > if (!wm->enable) > return; > -- > 1.8.3.2 > > _______________________________________________ > Intel-gfx mailing list > Intel-gfx@lists.freedesktop.org > http://lists.freedesktop.org/mailman/listinfo/intel-gfx
diff --git a/drivers/gpu/drm/i915/intel_pm.c b/drivers/gpu/drm/i915/intel_pm.c index e0d1c8b..e13937f 100644 --- a/drivers/gpu/drm/i915/intel_pm.c +++ b/drivers/gpu/drm/i915/intel_pm.c @@ -2206,8 +2206,11 @@ static void ilk_merge_wm_level(struct drm_device *dev, const struct intel_crtc *intel_crtc; list_for_each_entry(intel_crtc, &dev->mode_config.crtc_list, base.head) { - const struct intel_wm_level *wm = - &intel_crtc->wm.active.wm[level]; + const struct intel_pipe_wm *active = &intel_crtc->wm.active; + const struct intel_wm_level *wm = &active->wm[level]; + + if (!active->pipe_enabled) + continue; if (!wm->enable) return;