The patch number 10717 was added via Hans Verkuil <[email protected]>
to http://linuxtv.org/hg/v4l-dvb master development tree.
Kernel patches in this development tree may be modified to be backward
compatible with older kernels. Compatibility modifications will be
removed before inclusion into the mainstream Kernel
If anyone has any objections, please let us know by sending a message to:
Linux Media Mailing List <[email protected]>
------
From: Hans Verkuil <[email protected]>
zoran: TRY_FMT and S_FMT now do the same parameter checks.
Priority: normal
Signed-off-by: Hans Verkuil <[email protected]>
---
linux/drivers/media/video/zoran/zoran_driver.c | 12 ++++++++++--
1 file changed, 10 insertions(+), 2 deletions(-)
diff -r 3ab79d9002e1 -r 4e4f2ddbc8f1
linux/drivers/media/video/zoran/zoran_driver.c
--- a/linux/drivers/media/video/zoran/zoran_driver.c Wed Feb 18 22:33:35
2009 +0100
+++ b/linux/drivers/media/video/zoran/zoran_driver.c Wed Feb 18 22:34:55
2009 +0100
@@ -2132,8 +2132,6 @@ static int zoran_try_fmt_vid_out(struct
if (fmt->fmt.pix.pixelformat != V4L2_PIX_FMT_MJPEG)
return -EINVAL;
- fmt->fmt.pix.bytesperline = 0;
-
mutex_lock(&zr->resource_lock);
settings = fh->jpg_settings;
@@ -2158,6 +2156,14 @@ static int zoran_try_fmt_vid_out(struct
else
settings.field_per_buff = 1;
+ if (settings.HorDcm > 1) {
+ settings.img_x = (BUZ_MAX_WIDTH == 720) ? 8 : 0;
+ settings.img_width = (BUZ_MAX_WIDTH == 720) ? 704 :
BUZ_MAX_WIDTH;
+ } else {
+ settings.img_x = 0;
+ settings.img_width = BUZ_MAX_WIDTH;
+ }
+
/* check */
res = zoran_check_jpg_settings(zr, &settings, 1);
if (res)
@@ -2175,6 +2181,8 @@ static int zoran_try_fmt_vid_out(struct
V4L2_FIELD_TOP : V4L2_FIELD_BOTTOM);
fmt->fmt.pix.sizeimage = zoran_v4l2_calc_bufsize(&settings);
+ fmt->fmt.pix.bytesperline = 0;
+ fmt->fmt.pix.colorspace = V4L2_COLORSPACE_SMPTE170M;
tryfmt_unlock_and_return:
mutex_unlock(&zr->resource_lock);
return res;
---
Patch is available at:
http://linuxtv.org/hg/v4l-dvb/rev/4e4f2ddbc8f1b0463618a27a647b31b2de53bb74
_______________________________________________
linuxtv-commits mailing list
[email protected]
http://www.linuxtv.org/cgi-bin/mailman/listinfo/linuxtv-commits