From patchwork Wed Jul 6 08:58:44 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Claudiu Beznea X-Patchwork-Id: 12907603 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 4B9E5C433EF for ; Wed, 6 Jul 2022 08:57:30 +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:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-ID:Date:Subject:CC :To:From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=po0Xz1eXi/KLcK/vx8lXGVV6FKtKKTQof4myesIxTOA=; b=Mps7Y9JFaO00fh zU8ikV6tiqixYoKXO4/yqIY4c1dwzMkLxNbBhA5VA06hINXVyTeUquDEc92lEKFreW7HceXxa/bCk 7xfDVKca6YwvnKB4EnBetBBs9Ow6aowWVx/uHxi3ASViPpQybe6WPJjxyzbUy183JdYX61rf41WAv pOjrfv+Mtm+4+EG466ulLnoFtwnOm9QyW3EH0Ajxq4WINf7oFiODSdtGb7Z2V9zerDGB6ygu2zMuK Fyn1QDcOMACsiqFL+wWCj517TWNUxYrbPJKbRb9Ah8QKQZVGZ61ABitavCtRBnZNf7YYt2ldGhGei d/hF6WEmKRNlDJ5obEQw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1o90pi-007Xsp-7c; Wed, 06 Jul 2022 08:56:30 +0000 Received: from esa.microchip.iphmx.com ([68.232.154.123]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1o90pd-007Xr1-Qm for linux-arm-kernel@lists.infradead.org; Wed, 06 Jul 2022 08:56:27 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=microchip.com; i=@microchip.com; q=dns/txt; s=mchp; t=1657097785; x=1688633785; h=from:to:cc:subject:date:message-id:mime-version: content-transfer-encoding; bh=dXzeYA9cVkoxc6fZ0AVx6fTERxzncJqGTnR7aJd9/qc=; b=PkelwFzgYZrkrhRwQhszakeZHFgIrueqRi2SnicH9Xd6/iZRybxOr10d LYvnpnd1pafl5U+Evi3VDJVOl5QbsjZn7LTx9DLKcnUXb9ym75aqSF/00 6yFc980KtoZTiCE39NN6d/ZxUL/RF4Dk7QN59m3/JzOl4gB1uZGjhHBUe zMGzD2GPtCL7d71cYOR1Oqm4xBZUid+Qms1bC+nDLlLlmL3QXw1b3iQ3f oNeWHsyaDmH7I2i5GQYsE3Xqu24ePt6i4qta1GaxmK2FpNl0HXathKfbG Y1YYzvrHhyB2k10V/YPkD7rJ4rFXfpHDcJOjUzDNgS8y37mjl8Q3iE2G2 Q==; X-IronPort-AV: E=Sophos;i="5.92,249,1650956400"; d="scan'208";a="103245014" Received: from unknown (HELO email.microchip.com) ([170.129.1.10]) by esa6.microchip.iphmx.com with ESMTP/TLS/AES256-SHA256; 06 Jul 2022 01:56:21 -0700 Received: from chn-vm-ex02.mchp-main.com (10.10.85.144) by chn-vm-ex01.mchp-main.com (10.10.85.143) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.17; Wed, 6 Jul 2022 01:56:21 -0700 Received: from localhost.localdomain (10.10.115.15) by chn-vm-ex02.mchp-main.com (10.10.85.144) with Microsoft SMTP Server id 15.1.2375.17 via Frontend Transport; Wed, 6 Jul 2022 01:56:19 -0700 From: Claudiu Beznea To: , , , CC: , , , Claudiu Beznea Subject: [PATCH] crypto: atmel-sha: initialize sha_dd while declaring Date: Wed, 6 Jul 2022 11:58:44 +0300 Message-ID: <20220706085844.830650-1-claudiu.beznea@microchip.com> X-Mailer: git-send-email 2.33.0 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220706_015625_981012_0A8B1D51 X-CRM114-Status: UNSURE ( 9.69 ) 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: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Initialize sha_dd with platform_get_drvdata() when declaring it. Signed-off-by: Claudiu Beznea --- Hi, This patch is based on patch at [1]. [1] https://patchwork.kernel.org/project/linux-crypto/patch/20220705205144.131702-2-u.kleine-koenig@pengutronix.de Thank you, Claudiu Beznea drivers/crypto/atmel-sha.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/crypto/atmel-sha.c b/drivers/crypto/atmel-sha.c index e054e0ac6fc2..ca4b01926d1b 100644 --- a/drivers/crypto/atmel-sha.c +++ b/drivers/crypto/atmel-sha.c @@ -2666,9 +2666,7 @@ static int atmel_sha_probe(struct platform_device *pdev) static int atmel_sha_remove(struct platform_device *pdev) { - struct atmel_sha_dev *sha_dd; - - sha_dd = platform_get_drvdata(pdev); + struct atmel_sha_dev *sha_dd = platform_get_drvdata(pdev); spin_lock(&atmel_sha.lock); list_del(&sha_dd->list);