public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] mfd: Silence uninitialized variable warning for wm8994-core
@ 2012-04-05  3:49 Axel Lin
  2012-04-05  9:57 ` Mark Brown
  2012-04-16 15:37 ` Samuel Ortiz
  0 siblings, 2 replies; 3+ messages in thread
From: Axel Lin @ 2012-04-05  3:49 UTC (permalink / raw)
  To: linux-kernel; +Cc: Mark Brown, Samuel Ortiz

Fix below build warning:
  CC      drivers/mfd/wm8994-core.o
drivers/mfd/wm8994-core.c: In function 'wm8994_i2c_probe':
drivers/mfd/wm8994-core.c:582:7: warning: 'patch_regs' may be used uninitialized in this function [-Wuninitialized]
drivers/mfd/wm8994-core.c:393:14: note: 'patch_regs' was declared here

Signed-off-by: Axel Lin <axel.lin@gmail.com>
---
 drivers/mfd/wm8994-core.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/mfd/wm8994-core.c b/drivers/mfd/wm8994-core.c
index 9d7ca1e..bd02202 100644
--- a/drivers/mfd/wm8994-core.c
+++ b/drivers/mfd/wm8994-core.c
@@ -390,7 +390,7 @@ static __devinit int wm8994_device_init(struct wm8994 *wm8994, int irq)
 	struct regmap_config *regmap_config;
 	const struct reg_default *regmap_patch = NULL;
 	const char *devname;
-	int ret, i, patch_regs;
+	int ret, i, patch_regs = 0;
 	int pulls = 0;
 
 	dev_set_drvdata(wm8994->dev, wm8994);
-- 
1.7.5.4




^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2012-04-16 15:28 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-04-05  3:49 [PATCH] mfd: Silence uninitialized variable warning for wm8994-core Axel Lin
2012-04-05  9:57 ` Mark Brown
2012-04-16 15:37 ` Samuel Ortiz

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox