Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=ef207feddf826f099562b239543c447e68991b84
Commit:     ef207feddf826f099562b239543c447e68991b84
Parent:     0e614cd1a5a09b36a3b6d0fff8a08a97800d3cce
Author:     Chris Pascoe <[EMAIL PROTECTED]>
AuthorDate: Sun Dec 2 09:30:55 2007 -0300
Committer:  Mauro Carvalho Chehab <[EMAIL PROTECTED]>
CommitDate: Fri Jan 25 19:04:15 2008 -0200

    V4L/DVB (6897): xc2028: ignore HAS_IF during specific S-Code type searches
    
    If we are selecting the S-Code firmware to load by name, then we must mask
    off the HAS_IF bit during the search.
    
    Signed-off-by: Chris Pascoe <[EMAIL PROTECTED]>
    Signed-off-by: Mauro Carvalho Chehab <[EMAIL PROTECTED]>
---
 drivers/media/video/tuner-xc2028.c |   11 +++++++----
 1 files changed, 7 insertions(+), 4 deletions(-)

diff --git a/drivers/media/video/tuner-xc2028.c 
b/drivers/media/video/tuner-xc2028.c
index ddd94f1..1817bf6 100644
--- a/drivers/media/video/tuner-xc2028.c
+++ b/drivers/media/video/tuner-xc2028.c
@@ -395,6 +395,7 @@ static int seek_firmware(struct dvb_frontend *fe, unsigned 
int type,
 {
        struct xc2028_data *priv = fe->tuner_priv;
        int                 i, best_i = -1, best_nr_matches = 0;
+       unsigned int        ign_firm_type_mask = 0;
 
        tuner_dbg("%s called, want type=", __FUNCTION__);
        if (debug) {
@@ -412,16 +413,18 @@ static int seek_firmware(struct dvb_frontend *fe, 
unsigned int type,
 
        if (type & BASE)
                type &= BASE_TYPES;
-       else if (type & SCODE)
+       else if (type & SCODE) {
                type &= SCODE_TYPES;
-       else if (type & DTV_TYPES)
+               ign_firm_type_mask = HAS_IF;
+       } else if (type & DTV_TYPES)
                type &= DTV_TYPES;
        else if (type & STD_SPECIFIC_TYPES)
                type &= STD_SPECIFIC_TYPES;
 
        /* Seek for exact match */
        for (i = 0; i < priv->firm_size; i++) {
-               if ((type == priv->firm[i].type) && (*id == priv->firm[i].id))
+               if ((type == (priv->firm[i].type & ~ign_firm_type_mask)) &&
+                   (*id == priv->firm[i].id))
                        goto found;
        }
 
@@ -430,7 +433,7 @@ static int seek_firmware(struct dvb_frontend *fe, unsigned 
int type,
                v4l2_std_id match_mask;
                int nr_matches;
 
-               if (type != priv->firm[i].type)
+               if (type != (priv->firm[i].type & ~ign_firm_type_mask))
                        continue;
 
                match_mask = *id & priv->firm[i].id;
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to