diff options
author | Mauro Carvalho Chehab <mchehab@redhat.com> | 2013-04-25 14:40:21 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2013-04-25 15:07:04 -0400 |
commit | 7063c1456fc0a6366f467f10e7a35178ecc881ad (patch) | |
tree | 2f23756954a93b3085c07dea7da52732cf2cdf08 /drivers/media/tuners | |
parent | 751dc8c7fa706c6bafa0eeee88f22f59987157e0 (diff) |
[media] r820t: Remove a warning for an unused value
Currently, the driver complains about the pre_detect var:
drivers/media/tuners/r820t.c: In function 'r820t_sysfreq_sel':
drivers/media/tuners/r820t.c:722:31: warning: variable 'pre_dect' set but not used [-Wunused-but-set-variable]
While rtl8232 code comments it, perhaps some other driver may use.
So, the better is to keep the code there, allowing to enable it
via r820t config data.
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/tuners')
-rw-r--r-- | drivers/media/tuners/r820t.c | 7 | ||||
-rw-r--r-- | drivers/media/tuners/r820t.h | 1 |
2 files changed, 8 insertions, 0 deletions
diff --git a/drivers/media/tuners/r820t.c b/drivers/media/tuners/r820t.c index e6e7a06d2b40..4835021aa3b6 100644 --- a/drivers/media/tuners/r820t.c +++ b/drivers/media/tuners/r820t.c | |||
@@ -797,6 +797,13 @@ static int r820t_sysfreq_sel(struct r820t_priv *priv, u32 freq, | |||
797 | cable2_in = 0x00; | 797 | cable2_in = 0x00; |
798 | } | 798 | } |
799 | 799 | ||
800 | |||
801 | if (priv->cfg->use_predetect) { | ||
802 | rc = r820t_write_reg_mask(priv, 0x06, pre_dect, 0x40); | ||
803 | if (rc < 0) | ||
804 | return rc; | ||
805 | } | ||
806 | |||
800 | rc = r820t_write_reg_mask(priv, 0x1d, lna_top, 0xc7); | 807 | rc = r820t_write_reg_mask(priv, 0x1d, lna_top, 0xc7); |
801 | if (rc < 0) | 808 | if (rc < 0) |
802 | return rc; | 809 | return rc; |
diff --git a/drivers/media/tuners/r820t.h b/drivers/media/tuners/r820t.h index 4c0823b21693..48af3548027d 100644 --- a/drivers/media/tuners/r820t.h +++ b/drivers/media/tuners/r820t.h | |||
@@ -39,6 +39,7 @@ struct r820t_config { | |||
39 | enum r820t_chip rafael_chip; | 39 | enum r820t_chip rafael_chip; |
40 | unsigned max_i2c_msg_len; | 40 | unsigned max_i2c_msg_len; |
41 | bool use_diplexer; | 41 | bool use_diplexer; |
42 | bool use_predetect; | ||
42 | }; | 43 | }; |
43 | 44 | ||
44 | #if IS_ENABLED(CONFIG_MEDIA_TUNER_R820T) | 45 | #if IS_ENABLED(CONFIG_MEDIA_TUNER_R820T) |