]> git.hungrycats.org Git - linux/commitdiff
V4L: pvrusb2: Keep MPEG PTSs from drifting away
authorBoris Dores <babal@via.ecp.fr>
Mon, 3 Nov 2008 04:04:30 +0000 (23:04 -0500)
committerGreg Kroah-Hartman <gregkh@suse.de>
Mon, 10 Nov 2008 19:17:56 +0000 (11:17 -0800)
commit 3f93d1adca658201c64251c43a147cc79d468c3f upstream.

V4L: pvrusb2: Keep MPEG PTSs from drifting away

This change was empirically figured out by Boris Dores after
empirically comparing against behavior in the Windows driver.

Signed-off-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Signed-off-by: Michael Krufky <mkrufky@linuxtv.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/media/video/pvrusb2/pvrusb2-encoder.c

index c46d367f7472599ca8b57aeeddd52e2956c372a6..fbf80c69cf07b0a2867cef51024d86b786625a02 100644 (file)
@@ -403,6 +403,10 @@ static int pvr2_encoder_prep_config(struct pvr2_hdw *hdw)
        ret |= pvr2_encoder_vcmd(hdw, CX2341X_ENC_MISC,4, 0,3,0,0);
        ret |= pvr2_encoder_vcmd(hdw, CX2341X_ENC_MISC,4,15,0,0,0);
 
+       /* prevent the PTSs from slowly drifting away in the generated
+          MPEG stream */
+       ret |= pvr2_encoder_vcmd(hdw, CX2341X_ENC_MISC, 2, 4, 1);
+
        return ret;
 }