aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@redhat.com>2012-05-20 11:07:41 -0400
committerMauro Carvalho Chehab <mchehab@redhat.com>2012-05-20 11:07:41 -0400
commit6ae009a8ba512d5b07386bbb1172cfd7a02986aa (patch)
tree84725be02b8c81ee63604c2599e4293ee3be6d0d /drivers/media/video
parentefeb98b4e2b2ce50e008affce4c493e58167144a (diff)
[media] sta2x11_vip: Fix 60Hz video standard handling
This device supports V4L2_STD_ALL, but its check for 60Hz standards is broken, as NTSC is not the only standard that uses 60Hz. Cc: Federico Vaga <federico.vaga@gmail.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video')
-rw-r--r--drivers/media/video/sta2x11_vip.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/media/video/sta2x11_vip.c b/drivers/media/video/sta2x11_vip.c
index 636643f0a186..4c10205264d4 100644
--- a/drivers/media/video/sta2x11_vip.c
+++ b/drivers/media/video/sta2x11_vip.c
@@ -572,7 +572,7 @@ static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id *std)
572 return -EIO; 572 return -EIO;
573 *std = vip->std = newstd; 573 *std = vip->std = newstd;
574 if (oldstd != *std) { 574 if (oldstd != *std) {
575 if (V4L2_STD_NTSC & (*std)) 575 if (V4L2_STD_525_60 & (*std))
576 vip->format = formats_60[0]; 576 vip->format = formats_60[0];
577 else 577 else
578 vip->format = formats_50[0]; 578 vip->format = formats_50[0];
@@ -581,7 +581,7 @@ static int vidioc_s_std(struct file *file, void *priv, v4l2_std_id *std)
581 } 581 }
582 582
583 if (oldstd != *std) { 583 if (oldstd != *std) {
584 if (V4L2_STD_NTSC & (*std)) 584 if (V4L2_STD_525_60 & (*std))
585 vip->format = formats_60[0]; 585 vip->format = formats_60[0];
586 else 586 else
587 vip->format = formats_50[0]; 587 vip->format = formats_50[0];
@@ -804,7 +804,7 @@ static int vidioc_try_fmt_vid_cap(struct file *file, void *priv,
804 if (V4L2_PIX_FMT_UYVY != f->fmt.pix.pixelformat) 804 if (V4L2_PIX_FMT_UYVY != f->fmt.pix.pixelformat)
805 return -EINVAL; 805 return -EINVAL;
806 806
807 if (V4L2_STD_NTSC & vip->std) 807 if (V4L2_STD_525_60 & vip->std)
808 interlace_lim = 240; 808 interlace_lim = 240;
809 else 809 else
810 interlace_lim = 288; 810 interlace_lim = 288;