From patchwork Wed Dec 19 16:48:22 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Wolfram Sang X-Patchwork-Id: 10737781 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 E1A6913B5 for ; Wed, 19 Dec 2018 16:51:15 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id CED162B441 for ; Wed, 19 Dec 2018 16:51:15 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id C334C2B50C; Wed, 19 Dec 2018 16:51:15 +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=unavailable 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 7DAD22B441 for ; Wed, 19 Dec 2018 16:51:15 +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:References: In-Reply-To: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:List-Owner; bh=+yJBvfFvOuzsuTjOYikAKBkutnZ3PXmHyyojkquuE5w=; b=BAjldSm7qAL+4V/PfrBP+cd0Sy hs9URXFP4kAeQ7wkd+9AdnyYYtAQF9zSxhQZ3S0T65fmfFfwuPO9KyWEtfrQHPs/tirP77IL6pneb tpH4yJ5dn74nJXYaqChqU2fePjjSNLf5g2XeBtc72R3BC/aREBkkLoGyzFaDPEcmXXxHQyOkqXrRT JkiXug+yBu7crSi2vVkv1bh0LMEXZohL7wFBP8UFXVZLMScTBEeX2rX+mOv22pxkYNlg7yPgfUN2M QWc6SqjwlGwC3hcJoBq3BlqsKC+YkNUf2Dbco2rpw0EJ1F+NQnHj4nOWz5iAebtCghgJkjM1IF5Ju d65kNWUQ==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1gZf3w-0004cf-2S; Wed, 19 Dec 2018 16:51:12 +0000 Received: from sauhun.de ([88.99.104.3] helo=pokefinder.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1gZf1n-00014n-Mb for linux-arm-kernel@lists.infradead.org; Wed, 19 Dec 2018 16:49:05 +0000 Received: from localhost (p54B333DA.dip0.t-ipconnect.de [84.179.51.218]) by pokefinder.org (Postfix) with ESMTPSA id 265B62E35D3; Wed, 19 Dec 2018 17:48:38 +0100 (CET) From: Wolfram Sang To: linux-i2c@vger.kernel.org Subject: [PATCH 06/10] i2c: sprd: don't use pdev as variable name for struct device * Date: Wed, 19 Dec 2018 17:48:22 +0100 Message-Id: <20181219164827.20985-7-wsa+renesas@sang-engineering.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20181219164827.20985-1-wsa+renesas@sang-engineering.com> References: <20181219164827.20985-1-wsa+renesas@sang-engineering.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20181219_084901_389113_62A0A64F X-CRM114-Status: GOOD ( 10.69 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Wolfram Sang , Chunyan Zhang , linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org, linux-renesas-soc@vger.kernel.org, Hans de Goede , Baolin Wang , Orson Zhai , linux-arm-kernel@lists.infradead.org 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 pointer to a device is usually named 'dev'. These 'pdev' here look much like copy&paste errors. Fix them to avoid confusion. Signed-off-by: Wolfram Sang Reviewed-by: Baolin Wang --- drivers/i2c/busses/i2c-sprd.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/drivers/i2c/busses/i2c-sprd.c b/drivers/i2c/busses/i2c-sprd.c index a94e724f51dc..e266d8a713d9 100644 --- a/drivers/i2c/busses/i2c-sprd.c +++ b/drivers/i2c/busses/i2c-sprd.c @@ -586,40 +586,40 @@ static int sprd_i2c_remove(struct platform_device *pdev) return 0; } -static int __maybe_unused sprd_i2c_suspend_noirq(struct device *pdev) +static int __maybe_unused sprd_i2c_suspend_noirq(struct device *dev) { - struct sprd_i2c *i2c_dev = dev_get_drvdata(pdev); + struct sprd_i2c *i2c_dev = dev_get_drvdata(dev); i2c_lock_bus(&i2c_dev->adap, I2C_LOCK_ROOT_ADAPTER); i2c_dev->is_suspended = true; i2c_unlock_bus(&i2c_dev->adap, I2C_LOCK_ROOT_ADAPTER); - return pm_runtime_force_suspend(pdev); + return pm_runtime_force_suspend(dev); } -static int __maybe_unused sprd_i2c_resume_noirq(struct device *pdev) +static int __maybe_unused sprd_i2c_resume_noirq(struct device *dev) { - struct sprd_i2c *i2c_dev = dev_get_drvdata(pdev); + struct sprd_i2c *i2c_dev = dev_get_drvdata(dev); i2c_lock_bus(&i2c_dev->adap, I2C_LOCK_ROOT_ADAPTER); i2c_dev->is_suspended = false; i2c_unlock_bus(&i2c_dev->adap, I2C_LOCK_ROOT_ADAPTER); - return pm_runtime_force_resume(pdev); + return pm_runtime_force_resume(dev); } -static int __maybe_unused sprd_i2c_runtime_suspend(struct device *pdev) +static int __maybe_unused sprd_i2c_runtime_suspend(struct device *dev) { - struct sprd_i2c *i2c_dev = dev_get_drvdata(pdev); + struct sprd_i2c *i2c_dev = dev_get_drvdata(dev); clk_disable_unprepare(i2c_dev->clk); return 0; } -static int __maybe_unused sprd_i2c_runtime_resume(struct device *pdev) +static int __maybe_unused sprd_i2c_runtime_resume(struct device *dev) { - struct sprd_i2c *i2c_dev = dev_get_drvdata(pdev); + struct sprd_i2c *i2c_dev = dev_get_drvdata(dev); int ret; ret = clk_prepare_enable(i2c_dev->clk);