[PATCH 11/14] V4L/DVB (4427): Fix V4L1 Compat for VIDIOCGPICT ioctl

From: mchehab
Date: Tue Aug 08 2006 - 17:11:05 EST



From: Mauro Carvalho Chehab <mchehab@xxxxxxxxxxxxx>

Signed-off-by: Mauro Carvalho Chehab <mchehab@xxxxxxxxxxxxx>
---

drivers/media/video/v4l1-compat.c | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/drivers/media/video/v4l1-compat.c b/drivers/media/video/v4l1-compat.c
index d83a2c8..d7c3fcb 100644
--- a/drivers/media/video/v4l1-compat.c
+++ b/drivers/media/video/v4l1-compat.c
@@ -599,6 +599,10 @@ v4l_compat_translate_ioctl(struct inode
dprintk("VIDIOCGPICT / VIDIOC_G_FMT: %d\n",err);
break;
}
+
+ pict->depth = ((fmt2->fmt.pix.bytesperline<<3)
+ + (fmt2->fmt.pix.width-1) )
+ /fmt2->fmt.pix.width;
pict->palette = pixelformat_to_palette(
fmt2->fmt.pix.pixelformat);
break;

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/