Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp7516531imu; Tue, 22 Jan 2019 07:16:29 -0800 (PST) X-Google-Smtp-Source: ALg8bN7KuG2w/+xcV9/+sO2zcVgtgvUonKJQ+/fUWkyuTMs77hWGbkS0bJ389hHSrKSWrBVTC8tP X-Received: by 2002:a63:170c:: with SMTP id x12mr31617328pgl.364.1548170189263; Tue, 22 Jan 2019 07:16:29 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1548170189; cv=none; d=google.com; s=arc-20160816; b=jAQpoUt3a/yF6blUBtBrQx4Kgso5GZ8sm6Ehhnne8JY2CWUcSlGQT3h5LomI8ZszFj Yq41cVWTy7hQKStY//duGIf5rRyw8mM12D2E5ogsPuA01xqAJQmnujYU4lMFWSWe8P/L ilnyIyL1jS6JYg0dpQVpHD0ibx8rMaNIg/o8t0WwuaUeDx2h9lmLOdi89YjvqBX4jJEp 4DjBjkAb1btMifJ23frzgTfi7hihoqHqY8q04N/h7EnDaJ1LpTwmulE6WLVbXcQktFlo yd6dyFYO0+pgbUZjD5xWBZ5PW564YlmAyqlZZ2FwPHtG9enN2aul3y1wYGmA8VCSBsOS JCXQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=VAPOfW5CT70NGfBadBAS9ZmyCyj9jHbCw0jhwSDqFQU=; b=W01gAWlQlP2hm6fAwCOnQnDf4xuNiDaZdDxi5MSyqoOJauR4eaEc1cCLuFV0sR2MRM GLGV/RLDAq3cbuDDLX7ZGt7ZGsGnFwN3dsZaO1XL+Dx8MXreZL9ZuOphxkNksaILUS82 m53fIvqXxqDD7/uZy4Imxz15Sun9lWjm1Tsp1v+CxbVUKNYuFe21BhlyN5Vd++LgAnX9 K0shvc+OwkASkgVj+zJCXCndth+zetaZwi/ghdb5JwEh0nGgBohOcEYKVndaPjLkDy8X 5KRrIGbVWBx+0kFbqqf3dNFrYhxVlkzUgbhC5J6iOsHWbK1+QovOOEz88kd/vAAJT2sl OOmw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=yq4lADgY; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f186si8584685pfb.67.2019.01.22.07.16.10; Tue, 22 Jan 2019 07:16:29 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=yq4lADgY; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729276AbfAVPOm (ORCPT + 99 others); Tue, 22 Jan 2019 10:14:42 -0500 Received: from mail.kernel.org ([198.145.29.99]:54200 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729052AbfAVPOm (ORCPT ); Tue, 22 Jan 2019 10:14:42 -0500 Received: from localhost (5356596B.cm-6-7b.dynamic.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id D9BBF20879; Tue, 22 Jan 2019 15:14:40 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1548170081; bh=OcCJCJe5ytmFwd4tSUjrcn1s8QsLE07MJEyeEBuLv1g=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=yq4lADgYHa7g0/RLh8qYkIXE54BK6+kPTUh38UBzYhD69b9HkHynSIYOY1SDSq57U iiMp59vLlzaSan2hsleZ7hFCaBdDYfOJSdytkD6LrPicU1BWtP42vIzmj+KMVemmXM T0NvZCYn6pHhDhqLuIqHm8QbCOo9RtwLhLD+5UlE= From: Greg Kroah-Hartman To: Herbert Xu , David Miller Cc: linux-kernel@vger.kernel.org, linux-crypto@vger.kernel.org, Greg Kroah-Hartman , Jesper Nilsson , Lars Persson , linux-arm-kernel@axis.com Subject: [PATCH 3/7] crypto: axis: no need to check return value of debugfs_create functions Date: Tue, 22 Jan 2019 16:14:18 +0100 Message-Id: <20190122151422.14204-4-gregkh@linuxfoundation.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190122151422.14204-1-gregkh@linuxfoundation.org> References: <20190122151422.14204-1-gregkh@linuxfoundation.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org When calling debugfs functions, there is no need to ever check the return value. The function can work or not, but the code logic should never do something different based on this. Cc: Jesper Nilsson Cc: Lars Persson Cc: Herbert Xu Cc: "David S. Miller" Cc: linux-arm-kernel@axis.com Cc: linux-crypto@vger.kernel.org Signed-off-by: Greg Kroah-Hartman --- drivers/crypto/axis/artpec6_crypto.c | 9 --------- 1 file changed, 9 deletions(-) diff --git a/drivers/crypto/axis/artpec6_crypto.c b/drivers/crypto/axis/artpec6_crypto.c index f3442c2bdbdc..1a1858cea979 100644 --- a/drivers/crypto/axis/artpec6_crypto.c +++ b/drivers/crypto/axis/artpec6_crypto.c @@ -2984,12 +2984,6 @@ static void artpec6_crypto_init_debugfs(void) { dbgfs_root = debugfs_create_dir("artpec6_crypto", NULL); - if (!dbgfs_root || IS_ERR(dbgfs_root)) { - dbgfs_root = NULL; - pr_err("%s: Could not initialise debugfs!\n", MODULE_NAME); - return; - } - #ifdef CONFIG_FAULT_INJECTION fault_create_debugfs_attr("fail_status_read", dbgfs_root, &artpec6_crypto_fail_status_read); @@ -3001,9 +2995,6 @@ static void artpec6_crypto_init_debugfs(void) static void artpec6_crypto_free_debugfs(void) { - if (!dbgfs_root) - return; - debugfs_remove_recursive(dbgfs_root); dbgfs_root = NULL; } -- 2.20.1