From patchwork Mon Mar 6 04:42:05 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Herbert Xu X-Patchwork-Id: 13160472 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 1C90EC61DA4 for ; Mon, 6 Mar 2023 04:43:49 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:List-Subscribe:List-Help: List-Post:List-Archive:List-Unsubscribe:List-Id:Message-Id:To:References: Subject:Date:From:Reply-To:Cc:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To: List-Owner; bh=NhkjfHh72KRwJb1hjL3eDDc/h1FuMkSZus4bW+hDjcQ=; b=VmpuPrxvZ4uAMw djp2FB8eZGlfZs/jxllsF0e40JDgJZEwl/hjkeFcEk2wrHwnhVu+X1o2tHSxw8y/2N2y1OK3QdT8D 5k8mUFYxJHWE7oQd/9SDu8qoDS/WBynkOsMmGdEa3l7R3tgupWRnxCNnjUwsd35RW66rXkAsbS/xd 97SFfbRbIq46EpHjSiaDy6kSQMoUAeyDB1NE6AOmqIy7Bn5/7laxLQVb06RlVXu53Y8QbmdTIOBLu 8Rb3bXYBmHuAcL/JFBLJ7EAdzg1oYHMuifbiyjD7WdjXSZ67mev7wiZCm5bZvuAzt2xzGZ16moi6t NVfwbIQJ5jEKvE+LAbNQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1pZ2gS-00BHTg-O0; Mon, 06 Mar 2023 04:42:48 +0000 Received: from 167-179-156-38.a7b39c.syd.nbn.aussiebb.net ([167.179.156.38]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1pZ2fz-00BHJP-Aw for linux-arm-kernel@lists.infradead.org; Mon, 06 Mar 2023 04:42:20 +0000 Received: from loth.rohan.me.apana.org.au ([192.168.167.2]) by formenos.hmeau.com with smtp (Exim 4.94.2 #2 (Debian)) id 1pZ2fl-000e1P-NT; Mon, 06 Mar 2023 12:42:06 +0800 Received: by loth.rohan.me.apana.org.au (sSMTP sendmail emulation); Mon, 06 Mar 2023 12:42:05 +0800 From: "Herbert Xu" Date: Mon, 06 Mar 2023 12:42:05 +0800 Subject: [v5 PATCH 4/7] crypto: stm32 - Remove unused hdev->err field References: To: Linus Walleij , Lionel Debieve , Li kunyu , davem@davemloft.net, linux-arm-kernel@lists.infradead.org, linux-crypto@vger.kernel.org, linux-kernel@vger.kernel.org, linux-stm32@st-md-mailman.stormreply.com, mcoquelin.stm32@gmail.com Message-Id: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230305_204219_401599_5E5F602F X-CRM114-Status: UNSURE ( 8.59 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org The variable hdev->err is never read so it can be removed. Also remove a spurious inclusion of linux/crypto.h. Reviewed-by: Linus Walleij Tested-by: Linus Walleij Signed-off-by: Herbert Xu --- drivers/crypto/stm32/stm32-hash.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/crypto/stm32/stm32-hash.c b/drivers/crypto/stm32/stm32-hash.c index e16f9aaec6bf..e35fee945371 100644 --- a/drivers/crypto/stm32/stm32-hash.c +++ b/drivers/crypto/stm32/stm32-hash.c @@ -7,7 +7,6 @@ */ #include -#include #include #include #include @@ -183,7 +182,6 @@ struct stm32_hash_dev { struct ahash_request *req; struct crypto_engine *engine; - int err; unsigned long flags; struct dma_chan *dma_lch; @@ -894,7 +892,6 @@ static int stm32_hash_hw_init(struct stm32_hash_dev *hdev, stm32_hash_write(hdev, HASH_STR, 0); stm32_hash_write(hdev, HASH_DIN, 0); stm32_hash_write(hdev, HASH_IMR, 0); - hdev->err = 0; } return 0;