2 * ioctl32.c: Conversion between 32bit and 64bit native ioctls.
3 * Separated from fs stuff by Arnd Bergmann <arnd@arndb.de>
5 * Copyright (C) 1997-2000 Jakub Jelinek (jakub@redhat.com)
6 * Copyright (C) 1998 Eddie C. Dost (ecd@skynet.be)
7 * Copyright (C) 2001,2002 Andi Kleen, SuSE Labs
8 * Copyright (C) 2003 Pavel Machek (pavel@ucw.cz)
9 * Copyright (C) 2005 Philippe De Muyter (phdm@macqel.be)
10 * Copyright (C) 2008 Hans Verkuil <hverkuil@xs4all.nl>
12 * These routines maintain argument size conversion between 32bit and 64bit
16 #include <linux/compat.h>
17 #define __OLD_VIDIOC_ /* To allow fixing old calls*/
18 #include <linux/videodev2.h>
19 #include <linux/module.h>
20 #include <media/v4l2-ioctl.h>
24 static long native_ioctl(struct file *file, unsigned int cmd, unsigned long arg)
26 long ret = -ENOIOCTLCMD;
28 if (file->f_op->unlocked_ioctl)
29 ret = file->f_op->unlocked_ioctl(file, cmd, arg);
40 struct v4l2_window32 {
42 enum v4l2_field field;
44 compat_caddr_t clips; /* actually struct v4l2_clip32 * */
46 compat_caddr_t bitmap;
49 static int get_v4l2_window32(struct v4l2_window *kp, struct v4l2_window32 __user *up)
51 if (!access_ok(VERIFY_READ, up, sizeof(struct v4l2_window32)) ||
52 copy_from_user(&kp->w, &up->w, sizeof(up->w)) ||
53 get_user(kp->field, &up->field) ||
54 get_user(kp->chromakey, &up->chromakey) ||
55 get_user(kp->clipcount, &up->clipcount))
57 if (kp->clipcount > 2048)
60 struct v4l2_clip32 __user *uclips;
61 struct v4l2_clip __user *kclips;
62 int n = kp->clipcount;
65 if (get_user(p, &up->clips))
67 uclips = compat_ptr(p);
68 kclips = compat_alloc_user_space(n * sizeof(struct v4l2_clip));
71 if (copy_in_user(&kclips->c, &uclips->c, sizeof(uclips->c)))
73 if (put_user(n ? kclips + 1 : NULL, &kclips->next))
83 static int put_v4l2_window32(struct v4l2_window *kp, struct v4l2_window32 __user *up)
85 if (copy_to_user(&up->w, &kp->w, sizeof(kp->w)) ||
86 put_user(kp->field, &up->field) ||
87 put_user(kp->chromakey, &up->chromakey) ||
88 put_user(kp->clipcount, &up->clipcount))
93 static inline int get_v4l2_pix_format(struct v4l2_pix_format *kp, struct v4l2_pix_format __user *up)
95 if (copy_from_user(kp, up, sizeof(struct v4l2_pix_format)))
100 static inline int put_v4l2_pix_format(struct v4l2_pix_format *kp, struct v4l2_pix_format __user *up)
102 if (copy_to_user(up, kp, sizeof(struct v4l2_pix_format)))
107 static inline int get_v4l2_vbi_format(struct v4l2_vbi_format *kp, struct v4l2_vbi_format __user *up)
109 if (copy_from_user(kp, up, sizeof(struct v4l2_vbi_format)))
114 static inline int put_v4l2_vbi_format(struct v4l2_vbi_format *kp, struct v4l2_vbi_format __user *up)
116 if (copy_to_user(up, kp, sizeof(struct v4l2_vbi_format)))
121 static inline int get_v4l2_sliced_vbi_format(struct v4l2_sliced_vbi_format *kp, struct v4l2_sliced_vbi_format __user *up)
123 if (copy_from_user(kp, up, sizeof(struct v4l2_sliced_vbi_format)))
128 static inline int put_v4l2_sliced_vbi_format(struct v4l2_sliced_vbi_format *kp, struct v4l2_sliced_vbi_format __user *up)
130 if (copy_to_user(up, kp, sizeof(struct v4l2_sliced_vbi_format)))
135 struct v4l2_format32 {
136 enum v4l2_buf_type type;
138 struct v4l2_pix_format pix;
139 struct v4l2_window32 win;
140 struct v4l2_vbi_format vbi;
141 struct v4l2_sliced_vbi_format sliced;
142 __u8 raw_data[200]; /* user-defined */
146 static int get_v4l2_format32(struct v4l2_format *kp, struct v4l2_format32 __user *up)
148 if (!access_ok(VERIFY_READ, up, sizeof(struct v4l2_format32)) ||
149 get_user(kp->type, &up->type))
152 case V4L2_BUF_TYPE_VIDEO_CAPTURE:
153 case V4L2_BUF_TYPE_VIDEO_OUTPUT:
154 return get_v4l2_pix_format(&kp->fmt.pix, &up->fmt.pix);
155 case V4L2_BUF_TYPE_VIDEO_OVERLAY:
156 case V4L2_BUF_TYPE_VIDEO_OUTPUT_OVERLAY:
157 return get_v4l2_window32(&kp->fmt.win, &up->fmt.win);
158 case V4L2_BUF_TYPE_VBI_CAPTURE:
159 case V4L2_BUF_TYPE_VBI_OUTPUT:
160 return get_v4l2_vbi_format(&kp->fmt.vbi, &up->fmt.vbi);
161 case V4L2_BUF_TYPE_SLICED_VBI_CAPTURE:
162 case V4L2_BUF_TYPE_SLICED_VBI_OUTPUT:
163 return get_v4l2_sliced_vbi_format(&kp->fmt.sliced, &up->fmt.sliced);
164 case V4L2_BUF_TYPE_PRIVATE:
165 if (copy_from_user(kp, up, sizeof(kp->fmt.raw_data)))
171 printk(KERN_INFO "compat_ioctl32: unexpected VIDIOC_FMT type %d\n",
177 static int put_v4l2_format32(struct v4l2_format *kp, struct v4l2_format32 __user *up)
179 if (!access_ok(VERIFY_WRITE, up, sizeof(struct v4l2_format32)) ||
180 put_user(kp->type, &up->type))
183 case V4L2_BUF_TYPE_VIDEO_CAPTURE:
184 case V4L2_BUF_TYPE_VIDEO_OUTPUT:
185 return put_v4l2_pix_format(&kp->fmt.pix, &up->fmt.pix);
186 case V4L2_BUF_TYPE_VIDEO_OVERLAY:
187 case V4L2_BUF_TYPE_VIDEO_OUTPUT_OVERLAY:
188 return put_v4l2_window32(&kp->fmt.win, &up->fmt.win);
189 case V4L2_BUF_TYPE_VBI_CAPTURE:
190 case V4L2_BUF_TYPE_VBI_OUTPUT:
191 return put_v4l2_vbi_format(&kp->fmt.vbi, &up->fmt.vbi);
192 case V4L2_BUF_TYPE_SLICED_VBI_CAPTURE:
193 case V4L2_BUF_TYPE_SLICED_VBI_OUTPUT:
194 return put_v4l2_sliced_vbi_format(&kp->fmt.sliced, &up->fmt.sliced);
195 case V4L2_BUF_TYPE_PRIVATE:
196 if (copy_to_user(up, kp, sizeof(up->fmt.raw_data)))
202 printk(KERN_INFO "compat_ioctl32: unexpected VIDIOC_FMT type %d\n",
208 struct v4l2_standard32 {
210 __u32 id[2]; /* __u64 would get the alignment wrong */
212 struct v4l2_fract frameperiod; /* Frames, not fields */
217 static int get_v4l2_standard32(struct v4l2_standard *kp, struct v4l2_standard32 __user *up)
219 /* other fields are not set by the user, nor used by the driver */
220 if (!access_ok(VERIFY_READ, up, sizeof(struct v4l2_standard32)) ||
221 get_user(kp->index, &up->index))
226 static int put_v4l2_standard32(struct v4l2_standard *kp, struct v4l2_standard32 __user *up)
228 if (!access_ok(VERIFY_WRITE, up, sizeof(struct v4l2_standard32)) ||
229 put_user(kp->index, &up->index) ||
230 copy_to_user(up->id, &kp->id, sizeof(__u64)) ||
231 copy_to_user(up->name, kp->name, 24) ||
232 copy_to_user(&up->frameperiod, &kp->frameperiod, sizeof(kp->frameperiod)) ||
233 put_user(kp->framelines, &up->framelines) ||
234 copy_to_user(up->reserved, kp->reserved, 4 * sizeof(__u32)))
239 struct v4l2_buffer32 {
241 enum v4l2_buf_type type;
244 enum v4l2_field field;
245 struct compat_timeval timestamp;
246 struct v4l2_timecode timecode;
249 /* memory location */
250 enum v4l2_memory memory;
253 compat_long_t userptr;
260 static int get_v4l2_buffer32(struct v4l2_buffer *kp, struct v4l2_buffer32 __user *up)
263 if (!access_ok(VERIFY_READ, up, sizeof(struct v4l2_buffer32)) ||
264 get_user(kp->index, &up->index) ||
265 get_user(kp->type, &up->type) ||
266 get_user(kp->flags, &up->flags) ||
267 get_user(kp->memory, &up->memory) ||
268 get_user(kp->input, &up->input))
270 switch (kp->memory) {
271 case V4L2_MEMORY_MMAP:
272 if (get_user(kp->length, &up->length) ||
273 get_user(kp->m.offset, &up->m.offset))
276 case V4L2_MEMORY_USERPTR:
280 if (get_user(kp->length, &up->length) ||
281 get_user(tmp, &up->m.userptr))
284 kp->m.userptr = (unsigned long)compat_ptr(tmp);
287 case V4L2_MEMORY_OVERLAY:
288 if (get_user(kp->m.offset, &up->m.offset))
295 static int put_v4l2_buffer32(struct v4l2_buffer *kp, struct v4l2_buffer32 __user *up)
297 if (!access_ok(VERIFY_WRITE, up, sizeof(struct v4l2_buffer32)) ||
298 put_user(kp->index, &up->index) ||
299 put_user(kp->type, &up->type) ||
300 put_user(kp->flags, &up->flags) ||
301 put_user(kp->memory, &up->memory) ||
302 put_user(kp->input, &up->input))
304 switch (kp->memory) {
305 case V4L2_MEMORY_MMAP:
306 if (put_user(kp->length, &up->length) ||
307 put_user(kp->m.offset, &up->m.offset))
310 case V4L2_MEMORY_USERPTR:
311 if (put_user(kp->length, &up->length) ||
312 put_user(kp->m.userptr, &up->m.userptr))
315 case V4L2_MEMORY_OVERLAY:
316 if (put_user(kp->m.offset, &up->m.offset))
320 if (put_user(kp->bytesused, &up->bytesused) ||
321 put_user(kp->field, &up->field) ||
322 put_user(kp->timestamp.tv_sec, &up->timestamp.tv_sec) ||
323 put_user(kp->timestamp.tv_usec, &up->timestamp.tv_usec) ||
324 copy_to_user(&up->timecode, &kp->timecode, sizeof(struct v4l2_timecode)) ||
325 put_user(kp->sequence, &up->sequence) ||
326 put_user(kp->reserved, &up->reserved))
331 struct v4l2_framebuffer32 {
335 struct v4l2_pix_format fmt;
338 static int get_v4l2_framebuffer32(struct v4l2_framebuffer *kp, struct v4l2_framebuffer32 __user *up)
342 if (!access_ok(VERIFY_READ, up, sizeof(struct v4l2_framebuffer32)) ||
343 get_user(tmp, &up->base) ||
344 get_user(kp->capability, &up->capability) ||
345 get_user(kp->flags, &up->flags))
347 kp->base = compat_ptr(tmp);
348 get_v4l2_pix_format(&kp->fmt, &up->fmt);
352 static int put_v4l2_framebuffer32(struct v4l2_framebuffer *kp, struct v4l2_framebuffer32 __user *up)
354 u32 tmp = (u32)((unsigned long)kp->base);
356 if (!access_ok(VERIFY_WRITE, up, sizeof(struct v4l2_framebuffer32)) ||
357 put_user(tmp, &up->base) ||
358 put_user(kp->capability, &up->capability) ||
359 put_user(kp->flags, &up->flags))
361 put_v4l2_pix_format(&kp->fmt, &up->fmt);
365 struct v4l2_input32 {
366 __u32 index; /* Which input */
367 __u8 name[32]; /* Label */
368 __u32 type; /* Type of input */
369 __u32 audioset; /* Associated audios (bitfield) */
370 __u32 tuner; /* Associated tuner */
374 } __attribute__ ((packed));
376 /* The 64-bit v4l2_input struct has extra padding at the end of the struct.
377 Otherwise it is identical to the 32-bit version. */
378 static inline int get_v4l2_input32(struct v4l2_input *kp, struct v4l2_input32 __user *up)
380 if (copy_from_user(kp, up, sizeof(struct v4l2_input32)))
385 static inline int put_v4l2_input32(struct v4l2_input *kp, struct v4l2_input32 __user *up)
387 if (copy_to_user(up, kp, sizeof(struct v4l2_input32)))
392 struct v4l2_ext_controls32 {
397 compat_caddr_t controls; /* actually struct v4l2_ext_control32 * */
400 struct v4l2_ext_control32 {
407 compat_caddr_t string; /* actually char * */
409 } __attribute__ ((packed));
411 /* The following function really belong in v4l2-common, but that causes
412 a circular dependency between modules. We need to think about this, but
413 for now this will do. */
415 /* Return non-zero if this control is a pointer type. Currently only
416 type STRING is a pointer type. */
417 static inline int ctrl_is_pointer(u32 id)
420 case V4L2_CID_RDS_TX_PS_NAME:
421 case V4L2_CID_RDS_TX_RADIO_TEXT:
428 static int get_v4l2_ext_controls32(struct v4l2_ext_controls *kp, struct v4l2_ext_controls32 __user *up)
430 struct v4l2_ext_control32 __user *ucontrols;
431 struct v4l2_ext_control __user *kcontrols;
435 if (!access_ok(VERIFY_READ, up, sizeof(struct v4l2_ext_controls32)) ||
436 get_user(kp->ctrl_class, &up->ctrl_class) ||
437 get_user(kp->count, &up->count) ||
438 get_user(kp->error_idx, &up->error_idx) ||
439 copy_from_user(kp->reserved, up->reserved, sizeof(kp->reserved)))
446 if (get_user(p, &up->controls))
448 ucontrols = compat_ptr(p);
449 if (!access_ok(VERIFY_READ, ucontrols, n * sizeof(struct v4l2_ext_control)))
451 kcontrols = compat_alloc_user_space(n * sizeof(struct v4l2_ext_control));
452 kp->controls = kcontrols;
454 if (copy_in_user(kcontrols, ucontrols, sizeof(*kcontrols)))
456 if (ctrl_is_pointer(kcontrols->id)) {
459 if (get_user(p, &ucontrols->string))
462 if (put_user(s, &kcontrols->string))
471 static int put_v4l2_ext_controls32(struct v4l2_ext_controls *kp, struct v4l2_ext_controls32 __user *up)
473 struct v4l2_ext_control32 __user *ucontrols;
474 struct v4l2_ext_control __user *kcontrols = kp->controls;
478 if (!access_ok(VERIFY_WRITE, up, sizeof(struct v4l2_ext_controls32)) ||
479 put_user(kp->ctrl_class, &up->ctrl_class) ||
480 put_user(kp->count, &up->count) ||
481 put_user(kp->error_idx, &up->error_idx) ||
482 copy_to_user(up->reserved, kp->reserved, sizeof(up->reserved)))
487 if (get_user(p, &up->controls))
489 ucontrols = compat_ptr(p);
490 if (!access_ok(VERIFY_WRITE, ucontrols, n * sizeof(struct v4l2_ext_control)))
494 unsigned size = sizeof(*ucontrols);
496 /* Do not modify the pointer when copying a pointer control.
497 The contents of the pointer was changed, not the pointer
499 if (ctrl_is_pointer(kcontrols->id))
500 size -= sizeof(ucontrols->value64);
501 if (copy_in_user(ucontrols, kcontrols, size))
509 #define VIDIOC_G_FMT32 _IOWR('V', 4, struct v4l2_format32)
510 #define VIDIOC_S_FMT32 _IOWR('V', 5, struct v4l2_format32)
511 #define VIDIOC_QUERYBUF32 _IOWR('V', 9, struct v4l2_buffer32)
512 #define VIDIOC_G_FBUF32 _IOR ('V', 10, struct v4l2_framebuffer32)
513 #define VIDIOC_S_FBUF32 _IOW ('V', 11, struct v4l2_framebuffer32)
514 #define VIDIOC_QBUF32 _IOWR('V', 15, struct v4l2_buffer32)
515 #define VIDIOC_DQBUF32 _IOWR('V', 17, struct v4l2_buffer32)
516 #define VIDIOC_ENUMSTD32 _IOWR('V', 25, struct v4l2_standard32)
517 #define VIDIOC_ENUMINPUT32 _IOWR('V', 26, struct v4l2_input32)
518 #define VIDIOC_TRY_FMT32 _IOWR('V', 64, struct v4l2_format32)
519 #define VIDIOC_G_EXT_CTRLS32 _IOWR('V', 71, struct v4l2_ext_controls32)
520 #define VIDIOC_S_EXT_CTRLS32 _IOWR('V', 72, struct v4l2_ext_controls32)
521 #define VIDIOC_TRY_EXT_CTRLS32 _IOWR('V', 73, struct v4l2_ext_controls32)
523 #define VIDIOC_OVERLAY32 _IOW ('V', 14, s32)
525 #define VIDIOC_OVERLAY32_OLD _IOWR('V', 14, s32)
527 #define VIDIOC_STREAMON32 _IOW ('V', 18, s32)
528 #define VIDIOC_STREAMOFF32 _IOW ('V', 19, s32)
529 #define VIDIOC_G_INPUT32 _IOR ('V', 38, s32)
530 #define VIDIOC_S_INPUT32 _IOWR('V', 39, s32)
531 #define VIDIOC_G_OUTPUT32 _IOR ('V', 46, s32)
532 #define VIDIOC_S_OUTPUT32 _IOWR('V', 47, s32)
534 static long do_video_ioctl(struct file *file, unsigned int cmd, unsigned long arg)
537 struct v4l2_format v2f;
538 struct v4l2_buffer v2b;
539 struct v4l2_framebuffer v2fb;
540 struct v4l2_input v2i;
541 struct v4l2_standard v2s;
542 struct v4l2_ext_controls v2ecs;
546 void __user *up = compat_ptr(arg);
547 int compatible_arg = 1;
550 /* First, convert the command. */
552 case VIDIOC_G_FMT32: cmd = VIDIOC_G_FMT; break;
553 case VIDIOC_S_FMT32: cmd = VIDIOC_S_FMT; break;
554 case VIDIOC_QUERYBUF32: cmd = VIDIOC_QUERYBUF; break;
555 case VIDIOC_G_FBUF32: cmd = VIDIOC_G_FBUF; break;
556 case VIDIOC_S_FBUF32: cmd = VIDIOC_S_FBUF; break;
557 case VIDIOC_QBUF32: cmd = VIDIOC_QBUF; break;
558 case VIDIOC_DQBUF32: cmd = VIDIOC_DQBUF; break;
559 case VIDIOC_ENUMSTD32: cmd = VIDIOC_ENUMSTD; break;
560 case VIDIOC_ENUMINPUT32: cmd = VIDIOC_ENUMINPUT; break;
561 case VIDIOC_TRY_FMT32: cmd = VIDIOC_TRY_FMT; break;
562 case VIDIOC_G_EXT_CTRLS32: cmd = VIDIOC_G_EXT_CTRLS; break;
563 case VIDIOC_S_EXT_CTRLS32: cmd = VIDIOC_S_EXT_CTRLS; break;
564 case VIDIOC_TRY_EXT_CTRLS32: cmd = VIDIOC_TRY_EXT_CTRLS; break;
565 case VIDIOC_OVERLAY32: cmd = VIDIOC_OVERLAY; break;
567 case VIDIOC_OVERLAY32_OLD: cmd = VIDIOC_OVERLAY; break;
569 case VIDIOC_STREAMON32: cmd = VIDIOC_STREAMON; break;
570 case VIDIOC_STREAMOFF32: cmd = VIDIOC_STREAMOFF; break;
571 case VIDIOC_G_INPUT32: cmd = VIDIOC_G_INPUT; break;
572 case VIDIOC_S_INPUT32: cmd = VIDIOC_S_INPUT; break;
573 case VIDIOC_G_OUTPUT32: cmd = VIDIOC_G_OUTPUT; break;
574 case VIDIOC_S_OUTPUT32: cmd = VIDIOC_S_OUTPUT; break;
579 case VIDIOC_STREAMON:
580 case VIDIOC_STREAMOFF:
582 case VIDIOC_S_OUTPUT:
583 err = get_user(karg.vi, (s32 __user *)up);
588 case VIDIOC_G_OUTPUT:
595 err = get_v4l2_format32(&karg.v2f, up);
599 case VIDIOC_QUERYBUF:
602 err = get_v4l2_buffer32(&karg.v2b, up);
607 err = get_v4l2_framebuffer32(&karg.v2fb, up);
616 err = get_v4l2_standard32(&karg.v2s, up);
620 case VIDIOC_ENUMINPUT:
621 err = get_v4l2_input32(&karg.v2i, up);
625 case VIDIOC_G_EXT_CTRLS:
626 case VIDIOC_S_EXT_CTRLS:
627 case VIDIOC_TRY_EXT_CTRLS:
628 err = get_v4l2_ext_controls32(&karg.v2ecs, up);
636 err = native_ioctl(file, cmd, (unsigned long)up);
638 mm_segment_t old_fs = get_fs();
641 err = native_ioctl(file, cmd, (unsigned long)&karg);
645 /* Special case: even after an error we need to put the
646 results back for these ioctls since the error_idx will
647 contain information on which control failed. */
649 case VIDIOC_G_EXT_CTRLS:
650 case VIDIOC_S_EXT_CTRLS:
651 case VIDIOC_TRY_EXT_CTRLS:
652 if (put_v4l2_ext_controls32(&karg.v2ecs, up))
661 case VIDIOC_S_OUTPUT:
663 case VIDIOC_G_OUTPUT:
664 err = put_user(((s32)karg.vi), (s32 __user *)up);
668 err = put_v4l2_framebuffer32(&karg.v2fb, up);
674 err = put_v4l2_format32(&karg.v2f, up);
677 case VIDIOC_QUERYBUF:
680 err = put_v4l2_buffer32(&karg.v2b, up);
684 err = put_v4l2_standard32(&karg.v2s, up);
687 case VIDIOC_ENUMINPUT:
688 err = put_v4l2_input32(&karg.v2i, up);
694 long v4l2_compat_ioctl32(struct file *file, unsigned int cmd, unsigned long arg)
696 long ret = -ENOIOCTLCMD;
698 if (!file->f_op->unlocked_ioctl)
703 case VIDIOC_OVERLAY32_OLD:
704 case VIDIOC_S_PARM_OLD:
705 case VIDIOC_S_CTRL_OLD:
706 case VIDIOC_G_AUDIO_OLD:
707 case VIDIOC_G_AUDOUT_OLD:
708 case VIDIOC_CROPCAP_OLD:
710 case VIDIOC_QUERYCAP:
711 case VIDIOC_RESERVED:
712 case VIDIOC_ENUM_FMT:
716 case VIDIOC_QUERYBUF32:
717 case VIDIOC_G_FBUF32:
718 case VIDIOC_S_FBUF32:
719 case VIDIOC_OVERLAY32:
722 case VIDIOC_STREAMON32:
723 case VIDIOC_STREAMOFF32:
728 case VIDIOC_ENUMSTD32:
729 case VIDIOC_ENUMINPUT32:
736 case VIDIOC_QUERYCTRL:
737 case VIDIOC_QUERYMENU:
738 case VIDIOC_G_INPUT32:
739 case VIDIOC_S_INPUT32:
740 case VIDIOC_G_OUTPUT32:
741 case VIDIOC_S_OUTPUT32:
742 case VIDIOC_ENUMOUTPUT:
743 case VIDIOC_G_AUDOUT:
744 case VIDIOC_S_AUDOUT:
745 case VIDIOC_G_MODULATOR:
746 case VIDIOC_S_MODULATOR:
747 case VIDIOC_S_FREQUENCY:
748 case VIDIOC_G_FREQUENCY:
752 case VIDIOC_G_JPEGCOMP:
753 case VIDIOC_S_JPEGCOMP:
754 case VIDIOC_QUERYSTD:
755 case VIDIOC_TRY_FMT32:
756 case VIDIOC_ENUMAUDIO:
757 case VIDIOC_ENUMAUDOUT:
758 case VIDIOC_G_PRIORITY:
759 case VIDIOC_S_PRIORITY:
760 case VIDIOC_G_SLICED_VBI_CAP:
761 case VIDIOC_LOG_STATUS:
762 case VIDIOC_G_EXT_CTRLS32:
763 case VIDIOC_S_EXT_CTRLS32:
764 case VIDIOC_TRY_EXT_CTRLS32:
765 case VIDIOC_ENUM_FRAMESIZES:
766 case VIDIOC_ENUM_FRAMEINTERVALS:
767 case VIDIOC_G_ENC_INDEX:
768 case VIDIOC_ENCODER_CMD:
769 case VIDIOC_TRY_ENCODER_CMD:
770 case VIDIOC_DBG_S_REGISTER:
771 case VIDIOC_DBG_G_REGISTER:
772 case VIDIOC_DBG_G_CHIP_IDENT:
773 case VIDIOC_S_HW_FREQ_SEEK:
774 case VIDIOC_ENUM_DV_PRESETS:
775 case VIDIOC_S_DV_PRESET:
776 case VIDIOC_G_DV_PRESET:
777 case VIDIOC_QUERY_DV_PRESET:
778 case VIDIOC_S_DV_TIMINGS:
779 case VIDIOC_G_DV_TIMINGS:
781 case VIDIOC_SUBSCRIBE_EVENT:
782 case VIDIOC_UNSUBSCRIBE_EVENT:
783 ret = do_video_ioctl(file, cmd, arg);
787 printk(KERN_WARNING "compat_ioctl32: "
788 "unknown ioctl '%c', dir=%d, #%d (0x%08x)\n",
789 _IOC_TYPE(cmd), _IOC_DIR(cmd), _IOC_NR(cmd), cmd);
794 EXPORT_SYMBOL_GPL(v4l2_compat_ioctl32);
797 MODULE_LICENSE("GPL");