aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorroel kluin <roel.kluin@gmail.com>2008-07-21 20:29:46 -0400
committerMauro Carvalho Chehab <mchehab@infradead.org>2008-07-26 12:18:19 -0400
commit1ffdddd6fa3d18982133f6d149d456312d8bfcac (patch)
tree64e54f9ffd7fc7b9032bfd8594fe30d7ac99a1db
parente14b3658a7651ffd9b1f407eaf07f4dde17ef1e7 (diff)
V4L/DVB (8493): mt20xx: test below 0 on unsigned lo1a and lo2a
lo1a and lo2a are unsigned ints so these tests won't work. Signed-off-by: Roel Kluin <roel.kluin@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
-rw-r--r--drivers/media/common/tuners/mt20xx.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/media/common/tuners/mt20xx.c b/drivers/media/common/tuners/mt20xx.c
index fbcb28233737..35b763a16d53 100644
--- a/drivers/media/common/tuners/mt20xx.c
+++ b/drivers/media/common/tuners/mt20xx.c
@@ -148,7 +148,8 @@ static int mt2032_compute_freq(struct dvb_frontend *fe,
148 tuner_dbg("mt2032: rfin=%d lo2=%d lo2n=%d lo2a=%d num=%d lo2freq=%d\n", 148 tuner_dbg("mt2032: rfin=%d lo2=%d lo2n=%d lo2a=%d num=%d lo2freq=%d\n",
149 rfin,lo2,lo2n,lo2a,lo2num,lo2freq); 149 rfin,lo2,lo2n,lo2a,lo2num,lo2freq);
150 150
151 if(lo1a<0 || lo1a>7 || lo1n<17 ||lo1n>48 || lo2a<0 ||lo2a >7 ||lo2n<17 || lo2n>30) { 151 if (lo1a > 7 || lo1n < 17 || lo1n > 48 || lo2a > 7 || lo2n < 17 ||
152 lo2n > 30) {
152 tuner_info("mt2032: frequency parameters out of range: %d %d %d %d\n", 153 tuner_info("mt2032: frequency parameters out of range: %d %d %d %d\n",
153 lo1a, lo1n, lo2a,lo2n); 154 lo1a, lo1n, lo2a,lo2n);
154 return(-1); 155 return(-1);