From: Jiapeng Chong <jiapeng.chong@linux.alibaba.com>
To: loic.poulain@linaro.org
Cc: rfoss@kernel.org, andi.shyti@kernel.org,
linux-i2c@vger.kernel.org, linux-arm-msm@vger.kernel.org,
linux-kernel@vger.kernel.org,
Jiapeng Chong <jiapeng.chong@linux.alibaba.com>,
Abaci Robot <abaci@linux.alibaba.com>
Subject: [PATCH v2 -next] i2c: qcom-cci: Remove the unused variable cci_clk_rate
Date: Tue, 29 Oct 2024 10:09:31 +0800 [thread overview]
Message-ID: <20241029020931.42311-1-jiapeng.chong@linux.alibaba.com> (raw)
Variable ret is not effectively used, so delete it.
drivers/i2c/busses/i2c-qcom-cci.c:526:16: warning: variable ‘cci_clk_rate’ set but not used.
Reported-by: Abaci Robot <abaci@linux.alibaba.com>
Closes: https://bugzilla.openanolis.cn/show_bug.cgi?id=11532
Signed-off-by: Jiapeng Chong <jiapeng.chong@linux.alibaba.com>
---
Changes in v2:
-Remove redundant code.
drivers/i2c/busses/i2c-qcom-cci.c | 9 ---------
1 file changed, 9 deletions(-)
diff --git a/drivers/i2c/busses/i2c-qcom-cci.c b/drivers/i2c/busses/i2c-qcom-cci.c
index 5cc791b3b57d..a0ef43e99751 100644
--- a/drivers/i2c/busses/i2c-qcom-cci.c
+++ b/drivers/i2c/busses/i2c-qcom-cci.c
@@ -523,7 +523,6 @@ static const struct dev_pm_ops qcom_cci_pm = {
static int cci_probe(struct platform_device *pdev)
{
struct device *dev = &pdev->dev;
- unsigned long cci_clk_rate = 0;
struct device_node *child;
struct resource *r;
struct cci *cci;
@@ -594,14 +593,6 @@ static int cci_probe(struct platform_device *pdev)
return dev_err_probe(dev, -EINVAL, "not enough clocks in DT\n");
cci->nclocks = ret;
- /* Retrieve CCI clock rate */
- for (i = 0; i < cci->nclocks; i++) {
- if (!strcmp(cci->clocks[i].id, "cci")) {
- cci_clk_rate = clk_get_rate(cci->clocks[i].clk);
- break;
- }
- }
-
ret = cci_enable_clocks(cci);
if (ret < 0)
return ret;
--
2.32.0.3.g01195cf9f
next reply other threads:[~2024-10-29 2:09 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-10-29 2:09 Jiapeng Chong [this message]
2024-10-29 14:34 ` [PATCH v2 -next] i2c: qcom-cci: Remove the unused variable cci_clk_rate Dmitry Baryshkov
2024-10-30 10:53 ` Vladimir Zapolskiy
2024-10-31 10:44 ` Andi Shyti
2024-10-31 11:13 ` Vladimir Zapolskiy
2024-10-31 11:35 ` Vladimir Zapolskiy
2024-10-31 11:41 ` Andi Shyti
2024-10-31 11:59 ` Vladimir Zapolskiy
2024-10-31 12:23 ` Andi Shyti
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20241029020931.42311-1-jiapeng.chong@linux.alibaba.com \
--to=jiapeng.chong@linux.alibaba.com \
--cc=abaci@linux.alibaba.com \
--cc=andi.shyti@kernel.org \
--cc=linux-arm-msm@vger.kernel.org \
--cc=linux-i2c@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=loic.poulain@linaro.org \
--cc=rfoss@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox