Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S964849AbbGVLkG (ORCPT ); Wed, 22 Jul 2015 07:40:06 -0400 Received: from mail.fireflyinternet.com ([87.106.93.118]:58624 "EHLO fireflyinternet.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S933788AbbGVLkD (ORCPT ); Wed, 22 Jul 2015 07:40:03 -0400 X-Default-Received-SPF: pass (skip=forwardok (res=PASS)) x-ip-name=78.156.65.138; Date: Wed, 22 Jul 2015 12:39:37 +0100 From: Chris Wilson To: Sudip Mukherjee Cc: Daniel Vetter , Jani Nikula , David Airlie , intel-gfx@lists.freedesktop.org, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org Subject: Re: [Intel-gfx] [PATCH] drm/i915: add error path Message-ID: <20150722113937.GN6166@nuc-i3427.alporthouse.com> Mail-Followup-To: Chris Wilson , Sudip Mukherjee , Daniel Vetter , Jani Nikula , David Airlie , intel-gfx@lists.freedesktop.org, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org References: <1437564527-11667-1-git-send-email-sudipm.mukherjee@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1437564527-11667-1-git-send-email-sudipm.mukherjee@gmail.com> User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 840 Lines: 19 On Wed, Jul 22, 2015 at 04:58:47PM +0530, Sudip Mukherjee wrote: > If any of the debug file creation fails we were just returning the > error code to the drm layer. But the debug files that we created in the > process were not removed. And debugfs files are not automatically > cleaned up. Just handle the failure to add gracefully by only removing the ones we add during debugfs cleanup. One thing we do not actually want to do here is return an error - not setting up every file in debugfs shouldn't stop the driver from loading. -Chris -- Chris Wilson, Intel Open Source Technology Centre -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/