From mboxrd@z Thu Jan 1 00:00:00 1970 From: Daniel Vetter Subject: Re: [PATCH 2/5] drm/i915: make waiting trace events more useful Date: Wed, 2 May 2012 23:56:19 +0200 Message-ID: <20120502215619.GG4101@phenom.ffwll.local> References: <1335738156-27706-3-git-send-email-ben@bwidawsk.net> <1335836423-1164-1-git-send-email-ben@bwidawsk.net> <20120502211236.GC4101@phenom.ffwll.local> <1335993754_122897@CP5-2952> <20120502213615.GE4101@phenom.ffwll.local> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail-we0-f177.google.com (mail-we0-f177.google.com [74.125.82.177]) by gabe.freedesktop.org (Postfix) with ESMTP id DC2CF9E8CE for ; Wed, 2 May 2012 14:55:14 -0700 (PDT) Received: by werp11 with SMTP id p11so893281wer.36 for ; Wed, 02 May 2012 14:55:14 -0700 (PDT) Content-Disposition: inline In-Reply-To: <20120502213615.GE4101@phenom.ffwll.local> 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: Ben Widawsky , intel-gfx@lists.freedesktop.org List-Id: intel-gfx@lists.freedesktop.org On Wed, May 02, 2012 at 11:36:15PM +0200, Daniel Vetter wrote: > On Wed, May 02, 2012 at 10:22:33PM +0100, Chris Wilson wrote: > > On Wed, 2 May 2012 23:12:36 +0200, Daniel Vetter wrote: > > > For consistency I guess we can ditch the dev parameter (and even then, the > > > ring would uniquely identify the device). Also, I guess you need to > > > explicitly pass in blocking, because mutex_is_locked is rather racy - > > > someone else could hold the mutex while we're waiting in a non-blocking > > > fashion. > > > > Meh, I suggested the race - I'd rather have a moment of confusion > > reading the trace than reading the code in 6 months time. > > Ok, I see the problem and agree, let's have it slightly racy ... I've forgotten to add: Ben, please add the reasons why we decided to go with the racy variant to the commit messages, that kind of stuff is really important (otherwise the patch simply looks buggy). -Daniel -- Daniel Vetter Mail: daniel@ffwll.ch Mobile: +41 (0)79 365 57 48