aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/dvb/frontends/tda18271-tables.c
diff options
context:
space:
mode:
authorMichael Krufky <mkrufky@linuxtv.org>2008-01-05 15:42:54 -0300
committerMauro Carvalho Chehab <mchehab@infradead.org>2008-01-25 19:04:38 -0200
commitd2c932a1f7aca16727ce6670c5eccb0a4e2b47a5 (patch)
tree707c1c1ac999127b7afdf9889e41e9bff6a462eb /drivers/media/dvb/frontends/tda18271-tables.c
parentV4L/DVB (6964): tda18271: document debug level and configuration parameters (diff)
downloadlinux-dev-d2c932a1f7aca16727ce6670c5eccb0a4e2b47a5.tar.xz
linux-dev-d2c932a1f7aca16727ce6670c5eccb0a4e2b47a5.zip
V4L/DVB (6965): tda18271: fix analog tuning regression caused by earlier changeset
An earlier patch, "tda18271: fail table lookups if frequency is out of range" broke analog support on certain hardware. This patch fixes that problem, by allowing the RF_CAL byte to be set to the maximum value, in cases of the frequency being out of range. Signed-off-by: Michael Krufky <mkrufky@linuxtv.org> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to '')
-rw-r--r--drivers/media/dvb/frontends/tda18271-tables.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/media/dvb/frontends/tda18271-tables.c b/drivers/media/dvb/frontends/tda18271-tables.c
index 528a2ec9e967..0402c7dab19d 100644
--- a/drivers/media/dvb/frontends/tda18271-tables.c
+++ b/drivers/media/dvb/frontends/tda18271-tables.c
@@ -1098,7 +1098,7 @@ int tda18271_lookup_pll_map(struct dvb_frontend *fe,
}
while ((map[i].lomax * 1000) < *freq) {
- if (map[i].lomax == 0) {
+ if (map[i + 1].lomax == 0) {
tda_map("%s: frequency (%d) out of range\n",
map_name, *freq);
ret = -ERANGE;
@@ -1169,7 +1169,7 @@ int tda18271_lookup_map(struct dvb_frontend *fe,
}
while ((map[i].rfmax * 1000) < *freq) {
- if (map[i].rfmax == 0) {
+ if (map[i + 1].rfmax == 0) {
tda_map("%s: frequency (%d) out of range\n",
map_name, *freq);
ret = -ERANGE;