From patchwork Fri Nov 22 22:52:10 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Colin King X-Patchwork-Id: 11258563 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 4C95B13A4 for ; Fri, 22 Nov 2019 22:52:26 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id DDBDD2070E for ; Fri, 22 Nov 2019 22:52:25 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="sVd3rT7R" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org DDBDD2070E Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=canonical.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:Message-Id:Date:Subject: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=OxlgQrdE8z3cH9ynuOmvH8b385CrOAqP9qzkI5sEyqU=; b=sVd3rT7R3n72bA ZsANrNTl2MqrTI/ZvX0XxETSW28WlA8INcZg7QT1dK5OxeXnFvLq77gNVPMhyegXRoU9ktdhdzvHB XizETItiOGNotj/s0IGRLJK6X0cZGieX6RxoqWppxcvwdxsmWY26U4jGJydxUGXKTyBxc65Hlffdd 6KZP4V5ngLZL7cziYug+6osIYQXqY9ngPh5h5M9oIIgGLL7bW/K0xhsdeGNoNSJ3zSM6B3Pk4wIVY bhoYm0xoXoSChw3f3iETt3CFG0fx6QVpgCaVM4XADyJeQ56Q/pHqz8upBmU4XfVM7Zqaozuynu9IJ 6IRsEHhF/re/e3QBvtuA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1iYHmo-0006Y3-Dx; Fri, 22 Nov 2019 22:52:22 +0000 Received: from youngberry.canonical.com ([91.189.89.112]) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1iYHmk-0006P9-18; Fri, 22 Nov 2019 22:52:19 +0000 Received: from 1.general.cking.uk.vpn ([10.172.193.212] helo=localhost) by youngberry.canonical.com with esmtpsa (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.86_2) (envelope-from ) id 1iYHmd-0007Lc-5R; Fri, 22 Nov 2019 22:52:11 +0000 From: Colin King To: Alessandro Zummo , Alexandre Belloni , Kevin Hilman , linux-rtc@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-amlogic@lists.infradead.org Subject: [PATCH] rtc: meson: remove redundant assignment to variable retries Date: Fri, 22 Nov 2019 22:52:10 +0000 Message-Id: <20191122225210.109172-1-colin.king@canonical.com> X-Mailer: git-send-email 2.24.0 MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20191122_145218_260531_E2084F07 X-CRM114-Status: GOOD ( 10.39 ) X-Spam-Score: -5.0 (-----) X-Spam-Report: SpamAssassin version 3.4.2 on bombadil.infradead.org summary: Content analysis details: (-5.0 points) pts rule name description ---- ---------------------- -------------------------------------------------- -5.0 RCVD_IN_DNSWL_HI RBL: Sender listed at https://www.dnswl.org/, high trust [91.189.89.112 listed in list.dnswl.org] 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record 0.0 SPF_NONE SPF: sender does not publish an SPF Record X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: kernel-janitors@vger.kernel.org, linux-kernel@vger.kernel.org Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org From: Colin Ian King The variable retries is being initialized with a value that is never read and it is being updated later with a new value in a for-loop. The initialization is redundant and can be removed. Addresses-Coverity: ("Unused value") Signed-off-by: Colin Ian King Reviewed-by: Martin Blumenstingl --- drivers/rtc/rtc-meson.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/rtc/rtc-meson.c b/drivers/rtc/rtc-meson.c index 9bd8478db34b..47ebcf834cc2 100644 --- a/drivers/rtc/rtc-meson.c +++ b/drivers/rtc/rtc-meson.c @@ -131,7 +131,7 @@ static u32 meson_rtc_get_data(struct meson_rtc *rtc) static int meson_rtc_get_bus(struct meson_rtc *rtc) { - int ret, retries = 3; + int ret, retries; u32 val; /* prepare bus for transfers, set all lines low */