diff options
-rw-r--r-- | drivers/media/video/bt8xx/bttv-vbi.c | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/drivers/media/video/bt8xx/bttv-vbi.c b/drivers/media/video/bt8xx/bttv-vbi.c index 8c9f0f7cf467..63676e7bd635 100644 --- a/drivers/media/video/bt8xx/bttv-vbi.c +++ b/drivers/media/video/bt8xx/bttv-vbi.c | |||
@@ -31,11 +31,16 @@ | |||
31 | #include <asm/io.h> | 31 | #include <asm/io.h> |
32 | #include "bttvp.h" | 32 | #include "bttvp.h" |
33 | 33 | ||
34 | /* Offset from line sync pulse leading edge (0H) in 1 / sampling_rate: | 34 | /* Offset from line sync pulse leading edge (0H) to start of VBI capture, |
35 | bt8x8 /HRESET pulse starts at 0H and has length 64 / fCLKx1 (E|O_VTC | 35 | in fCLKx2 pixels. According to the datasheet, VBI capture starts |
36 | HSFMT = 0). VBI_HDELAY (always 0) is an offset from the trailing edge | 36 | VBI_HDELAY fCLKx1 pixels from the tailing edgeof /HRESET, and /HRESET |
37 | of /HRESET in 1 / fCLKx1, and the sampling_rate tvnorm->Fsc is fCLKx2. */ | 37 | is 64 fCLKx1 pixels wide. VBI_HDELAY is set to 0, so this should be |
38 | #define VBI_OFFSET ((64 + 0) * 2) | 38 | (64 + 0) * 2 = 128 fCLKx2 pixels. But it's not! The datasheet is |
39 | Just Plain Wrong. The real value appears to be different for | ||
40 | different revisions of the bt8x8 chips, and to be affected by the | ||
41 | horizontal scaling factor. Experimentally, the value is measured | ||
42 | to be about 244. */ | ||
43 | #define VBI_OFFSET 244 | ||
39 | 44 | ||
40 | #define VBI_DEFLINES 16 | 45 | #define VBI_DEFLINES 16 |
41 | #define VBI_MAXLINES 32 | 46 | #define VBI_MAXLINES 32 |