From mboxrd@z Thu Jan 1 00:00:00 1970 From: Laurent Pinchart Subject: Re: [PATCH 0/11] drm: add drm_send_vblank_event() helper (v4) Date: Tue, 16 Oct 2012 16:14:58 +0200 Message-ID: <3613136.pr0KuAkmr7@avalon> References: <1350086233-12426-1-git-send-email-rob.clark@linaro.org> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from perceval.ideasonboard.com (perceval.ideasonboard.com [95.142.166.194]) by gabe.freedesktop.org (Postfix) with ESMTP id 1C1D69F055 for ; Tue, 16 Oct 2012 07:14:12 -0700 (PDT) In-Reply-To: <1350086233-12426-1-git-send-email-rob.clark@linaro.org> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: dri-devel-bounces+sf-dri-devel=m.gmane.org@lists.freedesktop.org Errors-To: dri-devel-bounces+sf-dri-devel=m.gmane.org@lists.freedesktop.org To: Rob Clark Cc: patches@linaro.org, daniel.vetter@ffwll.ch, dri-devel@lists.freedesktop.org, bskeggs@redhat.com, gregkh@linuxfoundation.org, Rob Clark List-Id: dri-devel@lists.freedesktop.org Hi Rob, Thanks for the patch (0/11 looks a bit weird BTW). On Friday 12 October 2012 18:57:12 Rob Clark wrote: > From: Rob Clark > > A helper that drivers can use to send vblank event after a pageflip. > If the driver doesn't support proper vblank irq based time/seqn then > just pass -1 for the pipe # to get do_gettimestamp() behavior (since > there are a lot of drivers that don't use drm_vblank_count_and_time()) > > Also an internal send_vblank_event() helper for the various other code > paths within drm_irq that also need to send vblank events. > > v1: original > v2: add back 'vblwait->reply.sequence = seq' which should not have > been deleted > v3: add WARN_ON() in case lock is not held and comments > v4: use WARN_ON_SMP() instead to fix issue with !SMP && !DEBUG_SPINLOCK > as pointed out by Marcin Slusarz > > Signed-off-by: Rob Clark > --- > drivers/gpu/drm/drm_irq.c | 74 ++++++++++++++++++++++++++++-------------- > include/drm/drmP.h | 2 ++ Documentation/DocBook/drm.tmpl is missing ;-) > 2 files changed, 54 insertions(+), 22 deletions(-) I still wish we could have found a way to call drm_vblank_count_and_time() and do_gettimeofday() outside of the spinlock-protected region, but I won't complain. Apart from the missing documentation update the patch looks OK to me. -- Regards, Laurent Pinchart