Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751884AbbBKIdZ (ORCPT ); Wed, 11 Feb 2015 03:33:25 -0500 Received: from mail-we0-f171.google.com ([74.125.82.171]:56634 "EHLO mail-we0-f171.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751442AbbBKIdY (ORCPT ); Wed, 11 Feb 2015 03:33:24 -0500 From: Bas Peters To: kvalo@codeaurora.org Cc: Bas Peters , linville@tuxdriver.com, johannes.berg@intel.com, dcbw@redhat.com, libertas-dev@lists.infradead.org, linux-wireless@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] net: wireless: libertas: debugfs.c: remove unnecessary check before calling debugfs_remove Date: Wed, 11 Feb 2015 09:33:06 +0100 Message-Id: <1423643586-11002-1-git-send-email-baspeters93@gmail.com> X-Mailer: git-send-email 2.1.0 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 955 Lines: 30 Debugfs_remove will check for error or NULL for us, so it is not necessary to do this here. Signed-off-by: Bas Peters --- drivers/net/wireless/libertas/debugfs.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/net/wireless/libertas/debugfs.c b/drivers/net/wireless/libertas/debugfs.c index cc6a0a5..26cbf1d 100644 --- a/drivers/net/wireless/libertas/debugfs.c +++ b/drivers/net/wireless/libertas/debugfs.c @@ -742,8 +742,7 @@ void lbs_debugfs_init(void) void lbs_debugfs_remove(void) { - if (lbs_dir) - debugfs_remove(lbs_dir); + debugfs_remove(lbs_dir); } void lbs_debugfs_init_one(struct lbs_private *priv, struct net_device *dev) -- 2.1.0 -- 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/