[media] tda18218: fix compile warning
authorHans Verkuil <hverkuil@xs4all.nl>
Fri, 31 Dec 2010 15:26:53 +0000 (12:26 -0300)
committerMauro Carvalho Chehab <mchehab@redhat.com>
Tue, 4 Jan 2011 18:47:45 +0000 (16:47 -0200)
drivers/media/common/tuners/tda18218.c: In function 'tda18218_wr_regs':
drivers/media/common/tuners/tda18218.c:58:5: warning: 'ret' may be used uninitialized in this function

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
drivers/media/common/tuners/tda18218.c

index 8da1fdeddaa774b307f4cf229cafd4e1ee086cfb..aacfe2387e28393d7eaf1f436cbc06afd0d29182 100644 (file)
@@ -28,7 +28,7 @@ MODULE_PARM_DESC(debug, "Turn on/off debugging (default:off).");
 /* write multiple registers */
 static int tda18218_wr_regs(struct tda18218_priv *priv, u8 reg, u8 *val, u8 len)
 {
-       int ret;
+       int ret = 0;
        u8 buf[1+len], quotient, remainder, i, msg_len, msg_len_max;
        struct i2c_msg msg[1] = {
                {