From mboxrd@z Thu Jan 1 00:00:00 1970 From: Daniel Vetter Subject: Re: [PATCH] drm/i915: Treat resetting of the current framebuffer as a no-op Date: Thu, 23 May 2013 23:27:52 +0200 Message-ID: <20130523212752.GE15743@phenom.ffwll.local> References: <1369313837-31764-1-git-send-email-chris@chris-wilson.co.uk> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail-ee0-f41.google.com (mail-ee0-f41.google.com [74.125.83.41]) by gabe.freedesktop.org (Postfix) with ESMTP id 4F2E9E65B0 for ; Thu, 23 May 2013 14:27:57 -0700 (PDT) Received: by mail-ee0-f41.google.com with SMTP id d4so2254965eek.28 for ; Thu, 23 May 2013 14:27:56 -0700 (PDT) Content-Disposition: inline In-Reply-To: <1369313837-31764-1-git-send-email-chris@chris-wilson.co.uk> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: intel-gfx-bounces+gcfxdi-intel-gfx=m.gmane.org@lists.freedesktop.org Errors-To: intel-gfx-bounces+gcfxdi-intel-gfx=m.gmane.org@lists.freedesktop.org To: Chris Wilson Cc: intel-gfx@lists.freedesktop.org List-Id: intel-gfx@lists.freedesktop.org On Thu, May 23, 2013 at 01:57:17PM +0100, Chris Wilson wrote: > If none of the CRTC parameters change along with the framebuffer, we can > forgo rewriting the register and waiting for a vblank. There are a few > calls made by the display managers as they start up which tend to end up > performing no-ops on the current CRTC settings. > > Signed-off-by: Chris Wilson Makes sense. Queued for -next, thanks for the patch. Now the only things left (besides beating fastboot into good shape) is to cache the edids a bit and we've (hopefully) killed all kms stalls at startup ... -Daniel > --- > drivers/gpu/drm/i915/intel_display.c | 5 +++++ > 1 file changed, 5 insertions(+) > > diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c > index 981549c..f4450f1 100644 > --- a/drivers/gpu/drm/i915/intel_display.c > +++ b/drivers/gpu/drm/i915/intel_display.c > @@ -2286,6 +2286,11 @@ intel_pipe_set_base(struct drm_crtc *crtc, int x, int y, > return -EINVAL; > } > > + if (fb == crtc->fb && crtc->x == x && crtc->y == y) { > + DRM_DEBUG_KMS("skipping reset of current fb"); > + return 0; > + } > + > mutex_lock(&dev->struct_mutex); > ret = intel_pin_and_fence_fb_obj(dev, > to_intel_framebuffer(fb)->obj, > -- > 1.7.10.4 > > _______________________________________________ > Intel-gfx mailing list > Intel-gfx@lists.freedesktop.org > http://lists.freedesktop.org/mailman/listinfo/intel-gfx -- Daniel Vetter Software Engineer, Intel Corporation +41 (0) 79 365 57 48 - http://blog.ffwll.ch