From patchwork Fri Feb 18 10:17:07 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Claudiu Beznea X-Patchwork-Id: 12751256 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 43394C433EF for ; Fri, 18 Feb 2022 10:17:53 +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:References:In-Reply-To: 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: List-Owner; bh=fl9U7QM31V5F4VHj4WMN0xlmMzOIeF7TkadWkeBgRug=; b=gXJfV98KyzKN4d VwGTxndz/dqw56oXQQ+JGfHhWYEvmqojWIqYkRi8l6dP/7QvxLh4FGQrObXbr0pAm+JL2M+FJvJJz +82SCST906eQSv3hQCj7VoE2Fe4iwsY8ZLJrILXd1dMvMRo/8gKfBfch6Og7Fz/yWd9TjBc2Gq/6o OsDHVGDqXvzHRRZaub2gQdF5o6KHLgmRu313toAcyeS78goST8hy9HZzwNOOTKtpUnsLaiYG2F+nC IiV9Z2rwZVOQEy2MmzmuiyAzB6l407MHqSmxEXO4tx3TtQR1g6euQ9W1Dh4StcL6CRVpUAJxmIDSy 1eBK1ggtgYesoiski/ag==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1nL0Jh-00DnCH-2E; Fri, 18 Feb 2022 10:16:45 +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 1nL0JA-00DmxA-UA for linux-arm-kernel@lists.infradead.org; Fri, 18 Feb 2022 10:16:14 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=microchip.com; i=@microchip.com; q=dns/txt; s=mchp; t=1645179372; x=1676715372; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=x4B8RAQ+sONeCB93qo7wNP3O6nHHIZlxDecPSenuJqU=; b=0mDkD0fWyZy3eRkVNLClbHQNF58U0EwU3sFCp3AJms76OpkSGDL5hXEj al8beYmdJmD0GqfGRWrNZxj3rCajRBMF6mR0DjfpBrDBqfXXTMEqDqilB BER9jSzNT520SvWfqJqea/H6uausxGNmpTE0mAQepA9k6CBIgiInmeaF2 XaIshn7+bpYl8GKJzvyE2I4XDH00vdsnw/pkfixznXksq8xXDoe6qD9Yo PsHYHErzEdeNvEyoz4xkFw6TwGHpjbo+LiFv+B463rM2XQ+oBc3DMuIbX aKI+RlY6Oo4xamxvTRr+bISlcQqTLuWH87SUwy8Yn4lQQr636vx4WvMYo Q==; X-IronPort-AV: E=Sophos;i="5.88,378,1635231600"; d="scan'208";a="149200668" Received: from smtpout.microchip.com (HELO email.microchip.com) ([198.175.253.82]) by esa2.microchip.iphmx.com with ESMTP/TLS/AES256-SHA256; 18 Feb 2022 03:16:12 -0700 Received: from chn-vm-ex02.mchp-main.com (10.10.85.144) by chn-vm-ex04.mchp-main.com (10.10.85.152) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.17; Fri, 18 Feb 2022 03:16:12 -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; Fri, 18 Feb 2022 03:16:09 -0700 From: Claudiu Beznea To: , , , , CC: , , Claudiu Beznea Subject: [PATCH 2/7] hwrnd: atmel - disable trng on failure path Date: Fri, 18 Feb 2022 12:17:07 +0200 Message-ID: <20220218101712.530576-3-claudiu.beznea@microchip.com> X-Mailer: git-send-email 2.33.0 In-Reply-To: <20220218101712.530576-1-claudiu.beznea@microchip.com> References: <20220218101712.530576-1-claudiu.beznea@microchip.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220218_021613_026897_6AFD8F6F X-CRM114-Status: UNSURE ( 8.06 ) 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 Call atmel_trng_disable() on failure path of probe. Fixes: a1fa98d8116f ("hwrng: atmel - disable TRNG during suspend") Signed-off-by: Claudiu Beznea --- drivers/char/hw_random/atmel-rng.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/char/hw_random/atmel-rng.c b/drivers/char/hw_random/atmel-rng.c index 1a4874668c04..b7ef951927fb 100644 --- a/drivers/char/hw_random/atmel-rng.c +++ b/drivers/char/hw_random/atmel-rng.c @@ -131,6 +131,7 @@ static int atmel_trng_probe(struct platform_device *pdev) err_register: clk_disable_unprepare(trng->clk); + atmel_trng_disable(trng); return ret; }