Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=3d290bdb283c9dc897c5fd160fe3d07ead426c45
Commit:     3d290bdb283c9dc897c5fd160fe3d07ead426c45
Parent:     4ca7f7092815cad5cb3a9377dce211202fe4b328
Author:     Mike Isely <[EMAIL PROTECTED]>
AuthorDate: Mon Dec 3 01:47:12 2007 -0300
Committer:  Mauro Carvalho Chehab <[EMAIL PROTECTED]>
CommitDate: Fri Jan 25 19:03:08 2008 -0200

    V4L/DVB (6709): pvrusb2: minor rework for default video standard handling
    
    pvrusb2: When a per-device-type default video standard is declared,
    handle it in such a way that it can be correctly and unambiguously
    reported in the system log.
    
    Signed-off-by: Mike Isely <[EMAIL PROTECTED]>
    Signed-off-by: Mauro Carvalho Chehab <[EMAIL PROTECTED]>
---
 drivers/media/video/pvrusb2/pvrusb2-hdw.c |   18 +++++++++++++-----
 1 files changed, 13 insertions(+), 5 deletions(-)

diff --git a/drivers/media/video/pvrusb2/pvrusb2-hdw.c 
b/drivers/media/video/pvrusb2/pvrusb2-hdw.c
index 08b513b..54d2c4a 100644
--- a/drivers/media/video/pvrusb2/pvrusb2-hdw.c
+++ b/drivers/media/video/pvrusb2/pvrusb2-hdw.c
@@ -1441,9 +1441,6 @@ static v4l2_std_id get_default_standard(struct pvr2_hdw 
*hdw)
                tp = video_std[unit_number];
                if (tp) return tp;
        }
-       if (hdw->hdw_desc->default_std_mask) {
-               return hdw->hdw_desc->default_std_mask;
-       }
        return 0;
 }
 
@@ -1526,9 +1523,10 @@ static void pvr2_hdw_setup_std(struct pvr2_hdw *hdw)
 {
        char buf[40];
        unsigned int bcnt;
-       v4l2_std_id std1,std2;
+       v4l2_std_id std1,std2,std3;
 
        std1 = get_default_standard(hdw);
+       std3 = std1 ? 0 : hdw->hdw_desc->default_std_mask;
 
        bcnt = pvr2_std_id_to_str(buf,sizeof(buf),hdw->std_mask_eeprom);
        pvr2_trace(PVR2_TRACE_STD,
@@ -1538,7 +1536,7 @@ static void pvr2_hdw_setup_std(struct pvr2_hdw *hdw)
 
        hdw->std_mask_avail = hdw->std_mask_eeprom;
 
-       std2 = std1 & ~hdw->std_mask_avail;
+       std2 = (std1|std3) & ~hdw->std_mask_avail;
        if (std2) {
                bcnt = pvr2_std_id_to_str(buf,sizeof(buf),std2);
                pvr2_trace(PVR2_TRACE_STD,
@@ -1560,6 +1558,16 @@ static void pvr2_hdw_setup_std(struct pvr2_hdw *hdw)
                pvr2_hdw_internal_find_stdenum(hdw);
                return;
        }
+       if (std3) {
+               bcnt = pvr2_std_id_to_str(buf,sizeof(buf),std3);
+               pvr2_trace(PVR2_TRACE_STD,
+                          "Initial video standard"
+                          " (determined by device type): %.*s",bcnt,buf);
+               hdw->std_mask_cur = std3;
+               hdw->std_dirty = !0;
+               pvr2_hdw_internal_find_stdenum(hdw);
+               return;
+       }
 
        {
                unsigned int idx;
-
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