From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jesse Barnes Subject: Re: [PATCH 1/2] drm: add flags argument to crtc page_flip callback Date: Fri, 2 Nov 2012 09:00:52 -0700 Message-ID: <20121102090052.62db0473@jbarnes-desktop> References: <1351622029-2276-1-git-send-email-jbarnes@virtuousgeek.org> <1351622029-2276-2-git-send-email-jbarnes@virtuousgeek.org> <50934C16.6080800@tuebingen.mpg.de> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from oproxy9.bluehost.com (oproxy9.bluehost.com [69.89.24.6]) by gabe.freedesktop.org (Postfix) with SMTP id 58C459E860 for ; Fri, 2 Nov 2012 09:00:44 -0700 (PDT) In-Reply-To: <50934C16.6080800@tuebingen.mpg.de> 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: Mario Kleiner Cc: intel-gfx@lists.freedesktop.org List-Id: intel-gfx@lists.freedesktop.org On Fri, 02 Nov 2012 05:29:10 +0100 Mario Kleiner wrote: > On 30.10.12 19:33, Jesse Barnes wrote: > > This lets us pass down flags the drivers might be interested in, e.g. async. > > > > Signed-off-by: Jesse Barnes > > Hi Jesse > > I like it :) -- Anything that helps to get rid of the troublesome > 'SwapBuffersWait' madness in the ddx at some point makes me happy. > > > diff --git a/drivers/gpu/drm/drm_crtc.c b/drivers/gpu/drm/drm_crtc.c > > index ef1b221..b4964ac 100644 > > --- a/drivers/gpu/drm/drm_crtc.c > > +++ b/drivers/gpu/drm/drm_crtc.c > > @@ -3627,7 +3627,7 @@ int drm_mode_page_flip_ioctl(struct drm_device *dev, > > (void (*) (struct drm_pending_event *)) kfree; > > } > > > > - ret = crtc->funcs->page_flip(crtc, fb, e); > > + ret = crtc->funcs->page_flip(crtc, fb, e, flags); > > I think this should be page_flip->flags, ie. > > + ret = crtc->funcs->page_flip(crtc, fb, e, page_flip->flags); > > because flags is used here: > > > if (ret) { > > if (page_flip->flags & DRM_MODE_PAGE_FLIP_EVENT) { > > spin_lock_irqsave(&dev->event_lock, flags); > > to spin_lock_irqsave. > > As a tiny nit-pick, you sometimes name the variable 'flags', sometimes > 'flip_flags' in the different kms implementations below, which could be > made consistent. > > Reviewed-by: mario.kleiner@tuebingen.mpg.de > Yeah thanks. After I used 'flags' everywhere I saw the locking ones and changed some, but obviously didn't catch them all. :) I'll fix things up to be more consistent. Thanks, -- Jesse Barnes, Intel Open Source Technology Center