linux-i2c.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] i2c-mxs: fix compile warning in mxs_i2c_xfer()
@ 2011-11-24  7:52 Shawn Guo
       [not found] ` <1322121140-5216-1-git-send-email-shawn.guo-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>
  0 siblings, 1 reply; 12+ messages in thread
From: Shawn Guo @ 2011-11-24  7:52 UTC (permalink / raw)
  To: Ben Dooks
  Cc: Wolfram Sang, linux-i2c-u79uwXL29TY76Z2rM5mHXA,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r, Shawn Guo

  CC      drivers/i2c/busses/i2c-mxs.o
drivers/i2c/busses/i2c-mxs.c: In function ‘mxs_i2c_xfer’:
drivers/i2c/busses/i2c-mxs.c:196:6: warning: ‘data’ may be used uninitialized in this function

Signed-off-by: Shawn Guo <shawn.guo-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>
---
 drivers/i2c/busses/i2c-mxs.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/i2c/busses/i2c-mxs.c b/drivers/i2c/busses/i2c-mxs.c
index 7e78f7c..00f098f 100644
--- a/drivers/i2c/busses/i2c-mxs.c
+++ b/drivers/i2c/busses/i2c-mxs.c
@@ -193,7 +193,7 @@ static int mxs_i2c_wait_for_data(struct mxs_i2c_dev *i2c)
 
 static int mxs_i2c_finish_read(struct mxs_i2c_dev *i2c, u8 *buf, int len)
 {
-	u32 data;
+	u32 data = 0;
 	int i;
 
 	for (i = 0; i < len; i++) {
-- 
1.7.4.1

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

end of thread, other threads:[~2011-12-02 19:42 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-11-24  7:52 [PATCH] i2c-mxs: fix compile warning in mxs_i2c_xfer() Shawn Guo
     [not found] ` <1322121140-5216-1-git-send-email-shawn.guo-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>
2011-11-24  8:00   ` Wolfram Sang
     [not found]     ` <20111124080004.GD8439-bIcnvbaLZ9MEGnE8C9+IrQ@public.gmane.org>
2011-11-24  8:24       ` Shawn Guo
2011-11-24  8:29   ` Uwe Kleine-König
     [not found]     ` <20111124082903.GV19986-bIcnvbaLZ9MEGnE8C9+IrQ@public.gmane.org>
2011-11-24  8:37       ` Wolfram Sang
     [not found]         ` <20111124083747.GE8439-bIcnvbaLZ9MEGnE8C9+IrQ@public.gmane.org>
2011-11-24  9:02           ` Dong Aisheng-B29396
     [not found]             ` <65EE16ACC360FA4D99C96DC085B3F77233A4E4-TcFNo7jSaXPiTqIcKZ1S2K4g8xLGJsHaLnY5E4hWTkheoWH0uzbU5w@public.gmane.org>
2011-11-24  9:06               ` Uwe Kleine-König
     [not found]                 ` <20111124090653.GX19986-bIcnvbaLZ9MEGnE8C9+IrQ@public.gmane.org>
2011-11-24  9:09                   ` Dong Aisheng-B29396
2011-11-24  9:11             ` Lothar Waßmann
2011-11-25  1:15           ` Shawn Guo
     [not found]             ` <20111125011519.GA18403-+NayF8gZjK2ctlrPMvKcciBecyulp+rMXqFh9Ls21Oc@public.gmane.org>
2011-11-25  9:08               ` Wolfram Sang
     [not found]                 ` <20111125090806.GA2535-bIcnvbaLZ9MEGnE8C9+IrQ@public.gmane.org>
2011-12-02 19:42                   ` Marek Vasut

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).