From: Damien Lespiau Subject: Re: [PATCH 1/2] drm/i915: Move default: to the end of the switch Date: Wed, 5 Jun 2013 13:36:03 +0100 Message-ID: <20130605123603.GA5008@strange.amr.corp.intel.com> References: <1370430101-4764-1-git-send-email-damien.lespiau@intel.com> <87y5aolrt9.fsf@intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mga03.intel.com (mga03.intel.com [143.182.124.21]) by gabe.freedesktop.org (Postfix) with ESMTP id 01225E64FF for ; Wed, 5 Jun 2013 05:36:05 -0700 (PDT) Content-Disposition: inline In-Reply-To: <87y5aolrt9.fsf@intel.com> 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: Jani Nikula Cc: intel-gfx@lists.freedesktop.org List-Id: intel-gfx@lists.freedesktop.org On Wed, Jun 05, 2013 at 02:28:50PM +0300, Jani Nikula wrote: > On Wed, 05 Jun 2013, Damien Lespiau wrote: > > As it's usual to do, don't leave it in the middle of valid cases. > > > > Signed-off-by: Damien Lespiau > > --- > > drivers/gpu/drm/i915/i915_irq.c | 4 ++-- > > 1 file changed, 2 insertions(+), 2 deletions(-) > > > > diff --git a/drivers/gpu/drm/i915/i915_irq.c b/drivers/gpu/drm/i915/i915_irq.c > > index 63996aa..a8ef086 100644 > > --- a/drivers/gpu/drm/i915/i915_irq.c > > +++ b/drivers/gpu/drm/i915/i915_irq.c > > @@ -1484,14 +1484,14 @@ static void i915_get_extra_instdone(struct drm_device *dev, > > instdone[0] = I915_READ(INSTDONE_I965); > > instdone[1] = I915_READ(INSTDONE1); > > break; > > - default: > > - WARN_ONCE(1, "Unsupported platform\n"); > > This is a functional change because of the follow through here. The > commit message should reflect this. Hum indeed, it was probably intentional, trying to provide a default behaviour? never mind then (it could do with a comment I guess). -- Damien > > BR, > Jani. > > > case 7: > > instdone[0] = I915_READ(GEN7_INSTDONE_1); > > instdone[1] = I915_READ(GEN7_SC_INSTDONE); > > instdone[2] = I915_READ(GEN7_SAMPLER_INSTDONE); > > instdone[3] = I915_READ(GEN7_ROW_INSTDONE); > > break; > > + default: > > + WARN_ONCE(1, "Unsupported platform\n"); > > } > > } > > > > -- > > 1.8.1.4 > > > > _______________________________________________ > > Intel-gfx mailing list > > Intel-gfx@lists.freedesktop.org > > http://lists.freedesktop.org/mailman/listinfo/intel-gfx > > -- > Jani Nikula, Intel Open Source Technology Center