From patchwork Tue Oct 31 13:48:23 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Colin King X-Patchwork-Id: 10034563 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id B59F5600C5 for ; Tue, 31 Oct 2017 13:48:35 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id AA50128AA0 for ; Tue, 31 Oct 2017 13:48:35 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 9F5BD28AAB; Tue, 31 Oct 2017 13:48:35 +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=-6.9 required=2.0 tests=BAYES_00,RCVD_IN_DNSWL_HI autolearn=unavailable version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 6A25F28AA0 for ; Tue, 31 Oct 2017 13:48:35 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753443AbdJaNs0 (ORCPT ); Tue, 31 Oct 2017 09:48:26 -0400 Received: from youngberry.canonical.com ([91.189.89.112]:45085 "EHLO youngberry.canonical.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751876AbdJaNsZ (ORCPT ); Tue, 31 Oct 2017 09:48:25 -0400 Received: from 1.general.cking.uk.vpn ([10.172.193.212] helo=localhost) by youngberry.canonical.com with esmtpsa (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.76) (envelope-from ) id 1e9Wtz-0005Ya-MQ; Tue, 31 Oct 2017 13:48:23 +0000 From: Colin King To: Sebastian Reichel , linux-pm@vger.kernel.org Cc: kernel-janitors@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] power: supply: pcf50633-charger: remove redundant variable charging_start Date: Tue, 31 Oct 2017 13:48:23 +0000 Message-Id: <20171031134823.24997-1-colin.king@canonical.com> X-Mailer: git-send-email 2.14.1 MIME-Version: 1.0 Sender: linux-pm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pm@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Colin Ian King Variable charging_start is being set but is never read, it is therefore redundant and can be removed. Cleans up sparse warning: drivers/power/supply/pcf50633-charger.c:61:3: warning: Value stored to 'charging_start' is never read Signed-off-by: Colin Ian King --- drivers/power/supply/pcf50633-charger.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/drivers/power/supply/pcf50633-charger.c b/drivers/power/supply/pcf50633-charger.c index 1ad7ccce6075..1aba14046a83 100644 --- a/drivers/power/supply/pcf50633-charger.c +++ b/drivers/power/supply/pcf50633-charger.c @@ -43,7 +43,6 @@ int pcf50633_mbc_usb_curlim_set(struct pcf50633 *pcf, int ma) struct pcf50633_mbc *mbc = platform_get_drvdata(pcf->mbc_pdev); int ret = 0; u8 bits; - int charging_start = 1; u8 mbcs2, chgmod; unsigned int mbcc5; @@ -58,7 +57,6 @@ int pcf50633_mbc_usb_curlim_set(struct pcf50633 *pcf, int ma) ma = 100; } else { bits = PCF50633_MBCC7_USB_SUSPEND; - charging_start = 0; ma = 0; }