From mboxrd@z Thu Jan 1 00:00:00 1970 From: Daniel Vetter Subject: Re: [PATCH] drm/i915: Flush the pending flips on the CRTC before modification Date: Tue, 2 Oct 2012 11:52:23 +0200 Message-ID: <20121002095223.GD5679@phenom.ffwll.local> References: <1348777558-17881-1-git-send-email-chris@chris-wilson.co.uk> <20120928063720.GI2098@bremse> <275ffc$6pgut7@fmsmga002.fm.intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail-wg0-f43.google.com (mail-wg0-f43.google.com [74.125.82.43]) by gabe.freedesktop.org (Postfix) with ESMTP id C44849E78D for ; Tue, 2 Oct 2012 02:51:30 -0700 (PDT) Received: by wgbdq11 with SMTP id dq11so4188454wgb.12 for ; Tue, 02 Oct 2012 02:51:29 -0700 (PDT) Content-Disposition: inline In-Reply-To: <275ffc$6pgut7@fmsmga002.fm.intel.com> 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 Fri, Sep 28, 2012 at 01:04:03PM +0100, Chris Wilson wrote: > On Fri, 28 Sep 2012 08:37:20 +0200, Daniel Vetter wrote: > > On Thu, Sep 27, 2012 at 09:25:58PM +0100, Chris Wilson wrote: > > > This was meant to be the purpose of the > > > intel_crtc_wait_for_pending_flips() function which is called whilst > > > preparing the CRTC for a modeset or before disabling. However, as Ville > > > Syrjala pointed out, we set the pending flip notification on the old > > > framebuffer that is no longer attached to the CRTC by the time we come > > > to flush the pending operations. Instead, we can simply wait on the > > > pending unpin work to be finished on this CRTC, knowning that the > > > hardware has therefore finished modifying the registers, before proceeding > > > with our direct access. > > > > > > Signed-off-by: Chris Wilson > > > > Can I haz testcase plz? > > Fixes i-g-t/flip_test Picked up for -fixes (with the i-g-t note and cc: stable added), thanks for the patch. I've tried to make the test work on pch platforms, too. But those seem to simply complete the flip immediately when the pipe is off. -Daniel -- Daniel Vetter Software Engineer, Intel Corporation +41 (0) 79 365 57 48 - http://blog.ffwll.ch