diff options
author | Chris Pascoe <c.pascoe@itee.uq.edu.au> | 2007-12-02 04:54:17 -0500 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@infradead.org> | 2008-01-25 16:04:00 -0500 |
commit | 9ca01e780f8966a7a94f88ef5c54f340e117abea (patch) | |
tree | 0e69e0efa7b6b65ba7b60c3d4814800aed778d3d /drivers/media/video/tuner-xc2028.c | |
parent | ad35ce9e3e03b1515c8581bababb0e64d05cf1ad (diff) |
V4L/DVB (6853): xc2028: check HAS_IF flag against table
When searching for the right S-Code table to load, check the HAS_IF flag
against the firmware we are checking instead of against the the "type"
requested. We already ignore the scode type requested if the caller passed
an int_freq; this makes the search by frequency consistent with that behaviour.
Signed-off-by: Chris Pascoe <c.pascoe@itee.uq.edu.au>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers/media/video/tuner-xc2028.c')
-rw-r--r-- | drivers/media/video/tuner-xc2028.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/media/video/tuner-xc2028.c b/drivers/media/video/tuner-xc2028.c index 81cc7f607d4e..a6b05dfd6703 100644 --- a/drivers/media/video/tuner-xc2028.c +++ b/drivers/media/video/tuner-xc2028.c | |||
@@ -592,7 +592,7 @@ static int load_scode(struct dvb_frontend *fe, unsigned int type, | |||
592 | } else { | 592 | } else { |
593 | for (pos = 0; pos < priv->firm_size; pos++) { | 593 | for (pos = 0; pos < priv->firm_size; pos++) { |
594 | if ((priv->firm[pos].int_freq == int_freq) && | 594 | if ((priv->firm[pos].int_freq == int_freq) && |
595 | (type & HAS_IF)) | 595 | (priv->firm[pos].type & HAS_IF)) |
596 | break; | 596 | break; |
597 | } | 597 | } |
598 | if (pos == priv->firm_size) | 598 | if (pos == priv->firm_size) |
@@ -601,7 +601,7 @@ static int load_scode(struct dvb_frontend *fe, unsigned int type, | |||
601 | 601 | ||
602 | p = priv->firm[pos].ptr; | 602 | p = priv->firm[pos].ptr; |
603 | 603 | ||
604 | if (type & HAS_IF) { | 604 | if (priv->firm[pos].type & HAS_IF) { |
605 | if (priv->firm[pos].size != 12 * 16 || scode >= 16) | 605 | if (priv->firm[pos].size != 12 * 16 || scode >= 16) |
606 | return -EINVAL; | 606 | return -EINVAL; |
607 | p += 12 * scode; | 607 | p += 12 * scode; |