Commit 2e061730 authored by Andrew Morton's avatar Andrew Morton Committed by Linus Torvalds

[PATCH] v4l: cropcap ioctl fix

From: Gerd Knorr <kraxel@bytesex.org>

The VIDIOC_CROPCAP ioctl had wrong R/W bits, this patch fixes it.
parent d570ea4b
......@@ -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;
}
......
......@@ -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 */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment