summaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorDan Carpenter <dan.carpenter@oracle.com>2018-08-23 15:59:25 +0200
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>2018-08-24 11:52:34 +0200
commit5e2e2f9f76e157063a656351728703cb02b068f1 (patch)
tree8507dbeeae5c515971ff44d255c64d2dee90b508 /drivers
parentMerge tag 'pm-4.19-rc1-2' of git://git.kernel.org/pub/scm/linux/kernel/git/ra... (diff)
downloadlinux-5e2e2f9f76e157063a656351728703cb02b068f1.tar.xz
linux-5e2e2f9f76e157063a656351728703cb02b068f1.zip
PM / clk: signedness bug in of_pm_clk_add_clks()
"count" needs to be signed for the error handling to work. I made "i" signed as well so they match. Fixes: 02113ba93ea4 (PM / clk: Add support for obtaining clocks from device-tree) Cc: 4.6+ <stable@vger.kernel.org> # 4.6+ Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/base/power/clock_ops.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/base/power/clock_ops.c b/drivers/base/power/clock_ops.c
index 8e2e4757adcb..5a42ae4078c2 100644
--- a/drivers/base/power/clock_ops.c
+++ b/drivers/base/power/clock_ops.c
@@ -185,7 +185,7 @@ EXPORT_SYMBOL_GPL(of_pm_clk_add_clk);
int of_pm_clk_add_clks(struct device *dev)
{
struct clk **clks;
- unsigned int i, count;
+ int i, count;
int ret;
if (!dev || !dev->of_node)