From patchwork Thu Jun 20 18:35:25 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Krzysztof Kozlowski X-Patchwork-Id: 11007687 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 50E7B76 for ; Thu, 20 Jun 2019 18:35:50 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 40F342834A for ; Thu, 20 Jun 2019 18:35:50 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 34D3E284AF; Thu, 20 Jun 2019 18:35:50 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.2 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id CF05D2834A for ; Thu, 20 Jun 2019 18:35:49 +0000 (UTC) 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:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id: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=O1en8wLhmPdXlRZxgD59Z+oo6omt4KN5Qk/rXxqJ4i4=; b=aIQ 7nZ9A9LcIMOYkxAZX7HdRfnn8ebV+NZizPV7TM1pb/4SG1QSOaDlsJQt7ZKJY9B4ZBq7aZaEF7vVr fVQtw/ZD9VYkvyo/UHaHme15XH+bq73d0wYTuCOuNONzKd5IkHjd/A9dVk7S+S4msKXxt40xMD6ls 4u3r4Wvq4s3NBY6Z0F7PDjUIOwTzFMhKdkvHZu8E8lyjUVaLlCoBw3bKF5wGptxqd7ILx6a9eY+tq CvuKc7jKCBFBJT1qKCQQtwEOMMRMN75Vt53SlpaKQCiHhsYNbzbYtCPhk5r/J+1FipKM3FVjDZ/rj ek17T/e0qkAC47KsIzQy5uT2kcaTvaQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92 #3 (Red Hat Linux)) id 1he1uW-0000yA-Km; Thu, 20 Jun 2019 18:35:48 +0000 Received: from mail.kernel.org ([198.145.29.99]) by bombadil.infradead.org with esmtps (Exim 4.92 #3 (Red Hat Linux)) id 1he1uU-0000xp-Db for linux-arm-kernel@lists.infradead.org; Thu, 20 Jun 2019 18:35:47 +0000 Received: from localhost.localdomain (unknown [194.230.155.186]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id DBE0C206BF; Thu, 20 Jun 2019 18:35:42 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1561055745; bh=xj5NKVILW1vXpyLmUm8wT730CqgsMjGhUJ8Q/bucuKc=; h=From:To:Cc:Subject:Date:From; b=IHiBkNAUXc40eLbfxLFFk4XKgP7QLJLbr3cOakWdWeP4372jCubtsYBhhitfB8Ojg 3iP+fQyMON1vDjeunUQbG8zUtyj1MkBWHyCOAsVjif1t2BcPNu24AgbrbUjJV0NOQt Veg+ObXLWB4bEOKmYvTzszXwb4y5hAFQz7xO7gxg= From: Krzysztof Kozlowski To: Kukjin Kim , Krzysztof Kozlowski , Sangbeom Kim , Bartlomiej Zolnierkiewicz , Liam Girdwood , Mark Brown , Lee Jones , devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-samsung-soc@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 1/6] regulator: s2mps11: Consistently use local variable Date: Thu, 20 Jun 2019 20:35:25 +0200 Message-Id: <20190620183530.5386-1-krzk@kernel.org> X-Mailer: git-send-email 2.17.1 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190620_113546_477032_35EEA096 X-CRM114-Status: GOOD ( 13.14 ) 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: Sylwester Nawrocki , notify@kernel.org, Marek Szyprowski MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP The value under 's2mps11->ext_control_gpiod[i]' is assigned to local variable and used in probe in one place before. Use it consistently later so code will be easier to read. Signed-off-by: Krzysztof Kozlowski --- drivers/regulator/s2mps11.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/regulator/s2mps11.c b/drivers/regulator/s2mps11.c index af9bf10b4c33..e155c58061af 100644 --- a/drivers/regulator/s2mps11.c +++ b/drivers/regulator/s2mps11.c @@ -1194,7 +1194,7 @@ static int s2mps11_pmic_probe(struct platform_device *pdev) goto out; } - if (s2mps11->ext_control_gpiod[i]) { + if (config.ena_gpiod) { ret = s2mps14_pmic_enable_ext_control(s2mps11, regulator); if (ret < 0) {