lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Date:	Mon, 04 Jun 2012 09:59:09 +0800
From:	Axel Lin <axel.lin@...il.com>
To:	linux-kernel@...r.kernel.org
Cc:	Chiwoong Byun <woong.byun@...sung.com>,
	Jonghwa Lee <jonghwa3.lee@...sung.com>,
	Myungjoo Ham <myungjoo.ham@...sung.com>,
	Kyungmin Park <kyungmin.park@...sung.com>,
	Yadwinder Singh Brar <yadi.brar@...sung.com>,
	Mark Brown <broonie@...nsource.wolfsonmicro.com>,
	Liam Girdwood <lrg@...com>
Subject: [PATCH] regulator: max77686: Fix checkpatch warnings

Fix below checkpatch warnings:

$ scripts/checkpatch.pl -f drivers/regulator/max77686.c
ERROR: return is not a function, parentheses are not required
+       return (DIV_ROUND_UP(rdev->desc->uV_step

WARNING: line over 80 characters
+       .ops            = &max77686_buck_dvs_ops,                               \

total: 1 errors, 1 warnings, 339 lines checked

Signed-off-by: Axel Lin <axel.lin@...il.com>
---
 drivers/regulator/max77686.c |    9 +++++----
 1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/drivers/regulator/max77686.c b/drivers/regulator/max77686.c
index 4e9f4f3..0815de1 100644
--- a/drivers/regulator/max77686.c
+++ b/drivers/regulator/max77686.c
@@ -75,9 +75,10 @@ static int max77686_set_dvs_voltage_time_sel(struct regulator_dev *rdev,
 {
 	struct max77686_data *max77686 = rdev_get_drvdata(rdev);
 	int ramp_rate[] = {13, 27, 55, 100};
-	return (DIV_ROUND_UP(rdev->desc->uV_step
-			* abs(new_selector - old_selector),
-			ramp_rate[max77686->ramp_delay]));
+
+	return DIV_ROUND_UP(rdev->desc->uV_step *
+			    abs(new_selector - old_selector),
+			    ramp_rate[max77686->ramp_delay]);
 }
 
 static int max77686_set_voltage_time_sel(struct regulator_dev *rdev,
@@ -171,7 +172,7 @@ static struct regulator_ops max77686_buck_dvs_ops = {
 #define regulator_desc_buck_dvs(num)		{			\
 	.name		= "BUCK"#num,					\
 	.id		= MAX77686_BUCK##num,				\
-	.ops		= &max77686_buck_dvs_ops,				\
+	.ops		= &max77686_buck_dvs_ops,			\
 	.type		= REGULATOR_VOLTAGE,				\
 	.owner		= THIS_MODULE,					\
 	.min_uV		= MAX77686_DVS_MINUV,				\
-- 
1.7.9.5



--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ