summaryrefslogtreecommitdiff
path: root/drivers/media
diff options
context:
space:
mode:
authorPaul Bolle <pebolle@tiscali.nl>2012-11-01 23:24:30 +0400
committerBen Hutchings <ben@decadent.org.uk>2018-03-19 21:58:25 +0300
commit13ee32de97e76498fad43c6f424bb6c3025537dc (patch)
treecb36426c7a3b567f35dc71cdfee79ab4648430f2 /drivers/media
parent62623cb5c5e8ffe980b05cd02398a1d9b140e19b (diff)
downloadlinux-13ee32de97e76498fad43c6f424bb6c3025537dc.tar.xz
budget-av: only use t_state if initialized
commit cb31c7487580a0cfc6eb253e604c1e51ac8eb3c8 upstream. Building budget-av.o triggers this GCC warning: In file included from drivers/media/pci/ttpci/budget-av.c:44:0: drivers/media/dvb-frontends/tda8261_cfg.h: In function ‘tda8261_get_bandwidth’: drivers/media/dvb-frontends/tda8261_cfg.h:68:21: warning: ‘t_state.bandwidth’ may be used uninitialized in this function [-Wuninitialized] Move the printk() that uses t_state.bandwith to the location where it should be initialized to fix this. Signed-off-by: Paul Bolle <pebolle@tiscali.nl> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com> [bwh: Backported to 3.2: adjust filename] Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
Diffstat (limited to 'drivers/media')
-rw-r--r--drivers/media/dvb/frontends/tda8261_cfg.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/media/dvb/frontends/tda8261_cfg.h b/drivers/media/dvb/frontends/tda8261_cfg.h
index 1af1ee49b542..46710744173b 100644
--- a/drivers/media/dvb/frontends/tda8261_cfg.h
+++ b/drivers/media/dvb/frontends/tda8261_cfg.h
@@ -78,7 +78,7 @@ static int tda8261_get_bandwidth(struct dvb_frontend *fe, u32 *bandwidth)
return err;
}
*bandwidth = t_state.bandwidth;
+ printk("%s: Bandwidth=%d\n", __func__, t_state.bandwidth);
}
- printk("%s: Bandwidth=%d\n", __func__, t_state.bandwidth);
return 0;
}