aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video
diff options
context:
space:
mode:
authoraudetto@tiscali.it <audetto@tiscali.it>2006-12-12 08:35:57 -0500
committerMauro Carvalho Chehab <mchehab@infradead.org>2006-12-27 11:18:50 -0500
commit2485eb0a553f2ac8c73267ce48fcdee8a9728d43 (patch)
treeb8f042aff5add599d0359ac58e7ae198cd00637a /drivers/media/video
parentc6268461473e1c62e31afde657069c050ee8dea7 (diff)
V4L/DVB (4964): VIDEO_PALETTE_YUYV and VIDEO_PALETTE_YUV422 are the same palette
Consistent handling of VIDEO_PALETTE_YUYV and VIDEO_PALETTE_YUV422 Signed-off-by: Andrea A Odetti <audetto@tiscali.it> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers/media/video')
-rw-r--r--drivers/media/video/meye.c4
-rw-r--r--drivers/media/video/w9966.c2
-rw-r--r--drivers/media/video/zoran_device.c3
3 files changed, 5 insertions, 4 deletions
diff --git a/drivers/media/video/meye.c b/drivers/media/video/meye.c
index b083338823df..616a35da191d 100644
--- a/drivers/media/video/meye.c
+++ b/drivers/media/video/meye.c
@@ -923,7 +923,7 @@ static int meye_do_ioctl(struct inode *inode, struct file *file,
923 struct video_picture *p = arg; 923 struct video_picture *p = arg;
924 if (p->depth != 16) 924 if (p->depth != 16)
925 return -EINVAL; 925 return -EINVAL;
926 if (p->palette != VIDEO_PALETTE_YUV422) 926 if (p->palette != VIDEO_PALETTE_YUV422 && p->palette != VIDEO_PALETTE_YUYV)
927 return -EINVAL; 927 return -EINVAL;
928 mutex_lock(&meye.lock); 928 mutex_lock(&meye.lock);
929 sonypi_camera_command(SONYPI_COMMAND_SETCAMERABRIGHTNESS, 929 sonypi_camera_command(SONYPI_COMMAND_SETCAMERABRIGHTNESS,
@@ -978,7 +978,7 @@ static int meye_do_ioctl(struct inode *inode, struct file *file,
978 978
979 if (vm->frame >= gbuffers || vm->frame < 0) 979 if (vm->frame >= gbuffers || vm->frame < 0)
980 return -EINVAL; 980 return -EINVAL;
981 if (vm->format != VIDEO_PALETTE_YUV422) 981 if (vm->format != VIDEO_PALETTE_YUV422 && vm->format != VIDEO_PALETTE_YUYV)
982 return -EINVAL; 982 return -EINVAL;
983 if (vm->height * vm->width * 2 > gbufsize) 983 if (vm->height * vm->width * 2 > gbufsize)
984 return -EINVAL; 984 return -EINVAL;
diff --git a/drivers/media/video/w9966.c b/drivers/media/video/w9966.c
index 4bdc886abc4c..8d14f308f171 100644
--- a/drivers/media/video/w9966.c
+++ b/drivers/media/video/w9966.c
@@ -789,7 +789,7 @@ static int w9966_v4l_do_ioctl(struct inode *inode, struct file *file,
789 case VIDIOCSPICT: 789 case VIDIOCSPICT:
790 { 790 {
791 struct video_picture *vpic = arg; 791 struct video_picture *vpic = arg;
792 if (vpic->depth != 16 || vpic->palette != VIDEO_PALETTE_YUV422) 792 if (vpic->depth != 16 || (vpic->palette != VIDEO_PALETTE_YUV422 && vpic->palette != VIDEO_PALETTE_YUYV))
793 return -EINVAL; 793 return -EINVAL;
794 794
795 cam->brightness = vpic->brightness >> 8; 795 cam->brightness = vpic->brightness >> 8;
diff --git a/drivers/media/video/zoran_device.c b/drivers/media/video/zoran_device.c
index 168e431d7c71..b0752767ee4f 100644
--- a/drivers/media/video/zoran_device.c
+++ b/drivers/media/video/zoran_device.c
@@ -429,7 +429,7 @@ zr36057_set_vfe (struct zoran *zr,
429 reg |= (HorDcm << ZR36057_VFESPFR_HorDcm); 429 reg |= (HorDcm << ZR36057_VFESPFR_HorDcm);
430 reg |= (VerDcm << ZR36057_VFESPFR_VerDcm); 430 reg |= (VerDcm << ZR36057_VFESPFR_VerDcm);
431 reg |= (DispMode << ZR36057_VFESPFR_DispMode); 431 reg |= (DispMode << ZR36057_VFESPFR_DispMode);
432 if (format->palette != VIDEO_PALETTE_YUV422) 432 if (format->palette != VIDEO_PALETTE_YUV422 && format->palette != VIDEO_PALETTE_YUYV)
433 reg |= ZR36057_VFESPFR_LittleEndian; 433 reg |= ZR36057_VFESPFR_LittleEndian;
434 /* RJ: I don't know, why the following has to be the opposite 434 /* RJ: I don't know, why the following has to be the opposite
435 * of the corresponding ZR36060 setting, but only this way 435 * of the corresponding ZR36060 setting, but only this way
@@ -441,6 +441,7 @@ zr36057_set_vfe (struct zoran *zr,
441 reg |= ZR36057_VFESPFR_TopField; 441 reg |= ZR36057_VFESPFR_TopField;
442 switch (format->palette) { 442 switch (format->palette) {
443 443
444 case VIDEO_PALETTE_YUYV:
444 case VIDEO_PALETTE_YUV422: 445 case VIDEO_PALETTE_YUV422:
445 reg |= ZR36057_VFESPFR_YUV422; 446 reg |= ZR36057_VFESPFR_YUV422;
446 break; 447 break;