From mboxrd@z Thu Jan 1 00:00:00 1970 From: Daniel Vetter Subject: Re: [PATCH 1/5] drm/i915: WARN_ON failed map_and_fenceable Date: Sat, 10 Aug 2013 10:58:01 +0200 Message-ID: <20130810085801.GG31670@phenom.ffwll.local> References: <1376111536-12461-1-git-send-email-benjamin.widawsky@intel.com> <20130810084348.GC3561@cantiga.alporthouse.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail-ea0-f182.google.com (mail-ea0-f182.google.com [209.85.215.182]) by gabe.freedesktop.org (Postfix) with ESMTP id DBFF5E647F for ; Sat, 10 Aug 2013 01:57:54 -0700 (PDT) Received: by mail-ea0-f182.google.com with SMTP id o10so2484164eaj.13 for ; Sat, 10 Aug 2013 01:57:54 -0700 (PDT) Content-Disposition: inline In-Reply-To: <20130810084348.GC3561@cantiga.alporthouse.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: Chris Wilson , Ben Widawsky , Intel GFX , Ben Widawsky List-Id: intel-gfx@lists.freedesktop.org On Sat, Aug 10, 2013 at 09:43:48AM +0100, Chris Wilson wrote: > On Fri, Aug 09, 2013 at 10:12:12PM -0700, Ben Widawsky wrote: > > I just noticed in our code we don't really check the assertion, and > > given some of the code I am changing in this area, I feel a WARN is very > > nice to have. > > > > Signed-off-by: Ben Widawsky > > This is BUG() class. A WARN by itself here isn't going to prevent > calamity, so cleanup and let userspace die gracefully. The alternative > is random hw borkage (hopefully triggering an OOPS before it gets too > far). I think WARN is ok, there should be enough time for it to hit the logs before the evenutal machine death. Generally if a WARN requires us to add more cleanup code it's imo not worth it. -Daniel -- Daniel Vetter Software Engineer, Intel Corporation +41 (0) 79 365 57 48 - http://blog.ffwll.ch