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>] [thread-next>] [day] [month] [year] [list]
Message-Id: <1353550266-21330-1-git-send-email-qingx@marvell.com>
Date:	Thu, 22 Nov 2012 10:11:06 +0800
From:	Qing Xu <qingx@...vell.com>
To:	qingx@...vell.com, broonie@...nsource.wolfsonmicro.com, lrg@...com,
	haojian.zhuang@...il.com, cxie4@...vell.com,
	linux-kernel@...r.kernel.org
Subject: [PATCH] regulator: max8925: fix compiler warnings

From: Qing Xu <qingx@...vell.com>

Fixed following compiler warning:

- drivers/regulator/max8925-regulator.c:269:51: warning:
  'regulator_idx' may be used uninitialized in this function
  [-Wmaybe-uninitialized]

Signed-off-by: Qing Xu <qingx@...vell.com>
---
 drivers/regulator/max8925-regulator.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/drivers/regulator/max8925-regulator.c b/drivers/regulator/max8925-regulator.c
index 2b54979..187b29b 100644
--- a/drivers/regulator/max8925-regulator.c
+++ b/drivers/regulator/max8925-regulator.c
@@ -282,7 +282,8 @@ static int __devinit max8925_regulator_probe(struct platform_device *pdev)
 	struct max8925_regulator_info *ri;
 	struct resource *res;
 	struct regulator_dev *rdev;
-	int i, regulator_idx;
+	int i;
+	int regulator_idx = 0;
 
 	res = platform_get_resource(pdev, IORESOURCE_REG, 0);
 	if (!res) {
-- 
1.7.0.4

--
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