All of lore.kernel.org
 help / color / mirror / Atom feed
* [patch] v4l: cropcap ioctl fix
@ 2004-04-05 11:39 Gerd Knorr
  0 siblings, 0 replies; only message in thread
From: Gerd Knorr @ 2004-04-05 11:39 UTC (permalink / raw)
  To: Andrew Morton, Kernel List

  Hi,

The VIDIOC_CROPCAP ioctl had wrong R/W bits, this patch fixes it.

  Gerd

diff -up linux-2.6.5/drivers/media/video/videodev.c linux/drivers/media/video/videodev.c
--- linux-2.6.5/drivers/media/video/videodev.c	2004-04-05 10:39:15.988356075 +0200
+++ linux/drivers/media/video/videodev.c	2004-04-05 10:49:56.735503096 +0200
@@ -160,6 +160,9 @@ video_fix_command(unsigned int cmd)
 	case VIDIOC_G_AUDOUT_OLD:
 		cmd = VIDIOC_G_AUDOUT;
 		break;
+	case VIDIOC_CROPCAP_OLD:
+		cmd = VIDIOC_CROPCAP;
+		break;
 	}
 	return cmd;
 }
diff -up linux-2.6.5/include/linux/videodev2.h linux/include/linux/videodev2.h
--- linux-2.6.5/include/linux/videodev2.h	2004-04-05 10:41:49.838325804 +0200
+++ linux/include/linux/videodev2.h	2004-04-05 10:49:56.742501777 +0200
@@ -869,7 +869,7 @@ struct v4l2_streamparm
 #define VIDIOC_S_MODULATOR	_IOW  ('V', 55, struct v4l2_modulator)
 #define VIDIOC_G_FREQUENCY	_IOWR ('V', 56, struct v4l2_frequency)
 #define VIDIOC_S_FREQUENCY	_IOW  ('V', 57, struct v4l2_frequency)
-#define VIDIOC_CROPCAP		_IOR  ('V', 58, struct v4l2_cropcap)
+#define VIDIOC_CROPCAP		_IOWR ('V', 58, struct v4l2_cropcap)
 #define VIDIOC_G_CROP		_IOWR ('V', 59, struct v4l2_crop)
 #define VIDIOC_S_CROP		_IOW  ('V', 60, struct v4l2_crop)
 #define VIDIOC_G_JPEGCOMP	_IOR  ('V', 61, struct v4l2_jpegcompression)
@@ -887,6 +887,7 @@ struct v4l2_streamparm
 #define VIDIOC_S_CTRL_OLD      	_IOW  ('V', 28, struct v4l2_control)
 #define VIDIOC_G_AUDIO_OLD     	_IOWR ('V', 33, struct v4l2_audio)
 #define VIDIOC_G_AUDOUT_OLD    	_IOWR ('V', 49, struct v4l2_audioout)
+#define VIDIOC_CROPCAP_OLD     	_IOR  ('V', 58, struct v4l2_cropcap)
 
 #define BASE_VIDIOC_PRIVATE	192		/* 192-255 are private */
 

-- 
http://bigendian.bytesex.org

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2004-04-05 11:40 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-04-05 11:39 [patch] v4l: cropcap ioctl fix Gerd Knorr

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.