Commit c93350a6 authored by Hans Verkuil's avatar Hans Verkuil Committed by Mauro Carvalho Chehab

[media] af9033: fix compiler warnings

Fix two warnings:

af9033.c: In function 'af9033_read_status':
af9033.c:883:25: warning: 'snr_lut' may be used uninitialized in this function [-Wmaybe-uninitialized]
   const struct val_snr *snr_lut;
                         ^
af9033.c:952:25: warning: 'tmp' may be used uninitialized in this function [-Wmaybe-uninitialized]
   c->cnr.stat[0].svalue = tmp;
                         ^
Signed-off-by: default avatarHans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@s-opensource.com>
parent e34f2a96
...@@ -816,7 +816,7 @@ static int af9033_read_status(struct dvb_frontend *fe, enum fe_status *status) ...@@ -816,7 +816,7 @@ static int af9033_read_status(struct dvb_frontend *fe, enum fe_status *status)
{ {
struct af9033_dev *dev = fe->demodulator_priv; struct af9033_dev *dev = fe->demodulator_priv;
struct dtv_frontend_properties *c = &fe->dtv_property_cache; struct dtv_frontend_properties *c = &fe->dtv_property_cache;
int ret, i, tmp; int ret, i, tmp = 0;
u8 u8tmp, buf[7]; u8 u8tmp, buf[7];
dev_dbg(&dev->client->dev, "\n"); dev_dbg(&dev->client->dev, "\n");
...@@ -880,7 +880,7 @@ static int af9033_read_status(struct dvb_frontend *fe, enum fe_status *status) ...@@ -880,7 +880,7 @@ static int af9033_read_status(struct dvb_frontend *fe, enum fe_status *status)
/* CNR */ /* CNR */
if (dev->fe_status & FE_HAS_VITERBI) { if (dev->fe_status & FE_HAS_VITERBI) {
u32 snr_val, snr_lut_size; u32 snr_val, snr_lut_size;
const struct val_snr *snr_lut; const struct val_snr *snr_lut = NULL;
/* read value */ /* read value */
ret = af9033_rd_regs(dev, 0x80002c, buf, 3); ret = af9033_rd_regs(dev, 0x80002c, buf, 3);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment