From mboxrd@z Thu Jan 1 00:00:00 1970 From: Chris Wilson Subject: Re: [PATCH 11/12] drm/i915: Inline I915_INTERRUPT_ENABLE_FIX Date: Wed, 25 Apr 2012 22:28:21 +0100 Message-ID: <1335389337_51165@CP5-2952> References: <1335304792-17636-1-git-send-email-chris@chris-wilson.co.uk> <1335304792-17636-11-git-send-email-chris@chris-wilson.co.uk> <20120425135512.6307b991@jbarnes-desktop> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from fireflyinternet.com (smtp.fireflyinternet.com [109.228.6.236]) by gabe.freedesktop.org (Postfix) with ESMTP id 94B989E9A3 for ; Wed, 25 Apr 2012 14:29:00 -0700 (PDT) In-Reply-To: <20120425135512.6307b991@jbarnes-desktop> 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: Jesse Barnes Cc: intel-gfx@lists.freedesktop.org List-Id: intel-gfx@lists.freedesktop.org On Wed, 25 Apr 2012 13:55:12 -0700, Jesse Barnes wrote: > On Tue, 24 Apr 2012 22:59:51 +0100 > Chris Wilson wrote: > > + dev_priv->irq_mask = ~(I915_ASLE_INTERRUPT | > > + I915_DISPLAY_PIPE_A_EVENT_INTERRUPT | > > + I915_DISPLAY_PIPE_B_EVENT_INTERRUPT | > > + I915_DISPLAY_PLANE_A_FLIP_PENDING_INTERRUPT | > > + I915_DISPLAY_PLANE_B_FLIP_PENDING_INTERRUPT | > > + I915_RENDER_COMMAND_PARSER_ERROR_INTERRUPT); > > + > > + enable_mask = (I915_ASLE_INTERRUPT | > > + I915_DISPLAY_PIPE_A_EVENT_INTERRUPT | > > + I915_DISPLAY_PIPE_B_EVENT_INTERRUPT | > > + I915_DISPLAY_PLANE_A_FLIP_PENDING_INTERRUPT | > > + I915_DISPLAY_PLANE_B_FLIP_PENDING_INTERRUPT | > > + I915_RENDER_COMMAND_PARSER_ERROR_INTERRUPT | > > + I915_USER_INTERRUPT); > > You could set the enable mask to ~irq_mask | I915_USER_INTERRUPT I > think just to save a little duplication? No biggie though. I considered reducing the duplication, but having just done i8xx/i915 where the relationship between irq_mask and enable_mask was a little more complicated, I erred on the side of verbosity. enable_mask = ~dev_priv->irq_mask; enable_mask |= I915_USER_INTERRUPT; if (IS_G4X(dev)) enable_mask |= I915_BSD_USER_INTERRUPT; Works for me as well. -Chris -- Chris Wilson, Intel Open Source Technology Centre