diff options
author | Servaas Vandenberghe <vdb128@picaros.org> | 2007-04-29 15:27:30 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@infradead.org> | 2007-05-09 09:12:34 -0400 |
commit | ba70d59bb987110c4394e896b299f9726609aa33 (patch) | |
tree | 2d849a4e1f5484fec7e1809f12bdc8a4ce0bf087 /drivers/media/video/cx25840 | |
parent | 5c808e641741ecd7a7d5e65e38f740378d7406fc (diff) |
V4L/DVB (5576): Improve / fix support for PAL-60 in cx25840
This causes the cx25840 module to treat V4L2_STD_PAL_60 similar to
other 60Hz timings, and it fixes a wrongly-named variable (timings are
independant of color system).
Acked-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mike Isely <isely@pobox.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers/media/video/cx25840')
-rw-r--r-- | drivers/media/video/cx25840/cx25840-core.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/media/video/cx25840/cx25840-core.c b/drivers/media/video/cx25840/cx25840-core.c index 1757a588970f..67bda9f9a44b 100644 --- a/drivers/media/video/cx25840/cx25840-core.c +++ b/drivers/media/video/cx25840/cx25840-core.c | |||
@@ -555,7 +555,7 @@ static int set_v4lfmt(struct i2c_client *client, struct v4l2_format *fmt) | |||
555 | { | 555 | { |
556 | struct v4l2_pix_format *pix; | 556 | struct v4l2_pix_format *pix; |
557 | int HSC, VSC, Vsrc, Hsrc, filter, Vlines; | 557 | int HSC, VSC, Vsrc, Hsrc, filter, Vlines; |
558 | int is_pal = !(cx25840_get_v4lstd(client) & V4L2_STD_NTSC); | 558 | int is_50Hz = !(cx25840_get_v4lstd(client) & V4L2_STD_525_60); |
559 | 559 | ||
560 | switch (fmt->type) { | 560 | switch (fmt->type) { |
561 | case V4L2_BUF_TYPE_VIDEO_CAPTURE: | 561 | case V4L2_BUF_TYPE_VIDEO_CAPTURE: |
@@ -567,7 +567,7 @@ static int set_v4lfmt(struct i2c_client *client, struct v4l2_format *fmt) | |||
567 | Hsrc = (cx25840_read(client, 0x472) & 0x3f) << 4; | 567 | Hsrc = (cx25840_read(client, 0x472) & 0x3f) << 4; |
568 | Hsrc |= (cx25840_read(client, 0x471) & 0xf0) >> 4; | 568 | Hsrc |= (cx25840_read(client, 0x471) & 0xf0) >> 4; |
569 | 569 | ||
570 | Vlines = pix->height + (is_pal ? 4 : 7); | 570 | Vlines = pix->height + (is_50Hz ? 4 : 7); |
571 | 571 | ||
572 | if ((pix->width * 16 < Hsrc) || (Hsrc < pix->width) || | 572 | if ((pix->width * 16 < Hsrc) || (Hsrc < pix->width) || |
573 | (Vlines * 8 < Vsrc) || (Vsrc < Vlines)) { | 573 | (Vlines * 8 < Vsrc) || (Vsrc < Vlines)) { |