From mboxrd@z Thu Jan 1 00:00:00 1970 From: Chad Versace Subject: Re: [PATCH] drm/i915: Make i915 events part of uapi Date: Wed, 17 Jul 2013 14:12:21 -0700 Message-ID: <51E708B5.1000307@linux.intel.com> References: <1374018073-6596-1-git-send-email-ben@bwidawsk.net> <20130717050706.GZ5784@phenom.ffwll.local> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; Format="flowed" Content-Transfer-Encoding: 7bit Return-path: Received: from mga14.intel.com (mga14.intel.com [143.182.124.37]) by gabe.freedesktop.org (Postfix) with ESMTP id B332AE5C1F for ; Wed, 17 Jul 2013 14:12:24 -0700 (PDT) In-Reply-To: <20130717050706.GZ5784@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: Daniel Vetter Cc: Ben Widawsky , Intel GFX List-Id: intel-gfx@lists.freedesktop.org On 07/16/2013 10:07 PM, Daniel Vetter wrote: > On Tue, Jul 16, 2013 at 04:41:13PM -0700, Ben Widawsky wrote: >> Make the uevent strings part of the user API for people who wish to >> write their own listeners. >> >> CC: Chad Versace >> Signed-off-by: Ben Widawsky > > One thing I've toyed around with a bit is that we should add kerneldoc to > our uapi headers and create a DocBook out of it (maybe as a subsection in > the drm userspace api chapter). I guess the DocBook integration needs an > overall approach, but we should start to add comments to each piece of > userspace api to clearly spec them. See below for what I have in mind ... Yes, docs please. I don't have the kernel-fu of a kernel-dev, so without docs I don't know what these events mean and what to expect from them. >> - parity_event[0] = "L3_PARITY_ERROR=1"; >> + parity_event[0] = I915_L3_PARITY_EVENT"=1"; Small nitpick. I usually find string concatenation more readable like this, with a space: parity_event[0] = I915_L3_PARITY_EVENT "=1"; But, that's just my preference, so feel free to ignore me. >> +#define I915_L3_PARITY_EVENT "L3_PARITY_ERROR" >> +#define I915_ERROR_EVENT "ERROR" >> +#define I915_RESET_EVENT "RESET" Maybe this is a dumb question... since these are uevents, do you think the names would be improved by given them a "UEVENT" suffix? Like I915_ERROR_UEVENT? Or is that dumb, because these tokens are intended to serve more purposes than uevents?