]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - include/linux/videodev2.h
Merge master.kernel.org:/pub/scm/linux/kernel/git/davem/sparc-2.6
[linux-2.6-omap-h63xx.git] / include / linux / videodev2.h
index 27ae3d679cbeb901d9a7ffb0b025d725a2beba5e..af2d6155d3fe21208c8f03e33b3742f35425a71e 100644 (file)
 #include <linux/time.h> /* need struct timeval */
 #include <linux/poll.h>
 #include <linux/device.h>
+#include <linux/mutex.h>
 #endif
 #include <linux/compiler.h> /* need __user */
 
 
-#define OBSOLETE_OWNER 1 /* It will be removed for 2.6.15 */
+#define OBSOLETE_OWNER 1 /* It will be removed for 2.6.17 */
 #define HAVE_V4L2 1
 
 /*
 
 #ifdef __KERNEL__
 
+/* Minor device allocation */
+#define MINOR_VFL_TYPE_GRABBER_MIN   0
+#define MINOR_VFL_TYPE_GRABBER_MAX  63
+#define MINOR_VFL_TYPE_RADIO_MIN    64
+#define MINOR_VFL_TYPE_RADIO_MAX   127
+#define MINOR_VFL_TYPE_VTX_MIN     192
+#define MINOR_VFL_TYPE_VTX_MAX     223
+#define MINOR_VFL_TYPE_VBI_MIN     224
+#define MINOR_VFL_TYPE_VBI_MAX     255
+
 #define VFL_TYPE_GRABBER       0
 #define VFL_TYPE_VBI           1
 #define VFL_TYPE_RADIO         2
@@ -64,7 +75,7 @@ struct video_device
        int minor;
 
        /* device ops + callbacks */
-       struct file_operations *fops;
+       const struct file_operations *fops;
        void (*release)(struct video_device *vfd);
 
 
@@ -80,7 +91,7 @@ struct video_device
 
        /* for videodev.c intenal usage -- please don't touch */
        int users;                     /* video_exclusive_{open|close} ... */
-       struct semaphore lock;         /* ... helper function uses these   */
+       struct mutex lock;             /* ... helper function uses these   */
        char devfs_name[64];           /* devfs */
        struct class_device class_dev; /* sysfs */
 };
@@ -315,6 +326,7 @@ struct v4l2_pix_format
 #define V4L2_PIX_FMT_SN9C10X  v4l2_fourcc('S','9','1','0') /* SN9C10x compression */
 #define V4L2_PIX_FMT_PWC1     v4l2_fourcc('P','W','C','1') /* pwc older webcam */
 #define V4L2_PIX_FMT_PWC2     v4l2_fourcc('P','W','C','2') /* pwc newer webcam */
+#define V4L2_PIX_FMT_ET61X251 v4l2_fourcc('E','6','2','5') /* ET61X251 compression */
 
 /*
  *     F O R M A T   E N U M E R A T I O N
@@ -548,7 +560,7 @@ struct v4l2_framebuffer
 struct v4l2_clip
 {
        struct v4l2_rect        c;
-       struct v4l2_clip        *next;
+       struct v4l2_clip        __user *next;
 };
 
 struct v4l2_window
@@ -628,6 +640,7 @@ typedef __u64 v4l2_std_id;
 #define V4L2_STD_NTSC_M         ((v4l2_std_id)0x00001000)
 #define V4L2_STD_NTSC_M_JP      ((v4l2_std_id)0x00002000)
 #define V4L2_STD_NTSC_443       ((v4l2_std_id)0x00004000)
+#define V4L2_STD_NTSC_M_KR      ((v4l2_std_id)0x00008000)
 
 #define V4L2_STD_SECAM_B        ((v4l2_std_id)0x00010000)
 #define V4L2_STD_SECAM_D        ((v4l2_std_id)0x00020000)
@@ -660,7 +673,8 @@ typedef __u64 v4l2_std_id;
                                 V4L2_STD_PAL_H         |\
                                 V4L2_STD_PAL_I)
 #define V4L2_STD_NTSC           (V4L2_STD_NTSC_M       |\
-                                V4L2_STD_NTSC_M_JP)
+                                V4L2_STD_NTSC_M_JP     |\
+                                V4L2_STD_NTSC_M_KR)
 #define V4L2_STD_SECAM_DK              (V4L2_STD_SECAM_D       |\
                                 V4L2_STD_SECAM_K       |\
                                 V4L2_STD_SECAM_K1)
@@ -869,6 +883,7 @@ struct v4l2_modulator
 #define V4L2_TUNER_MODE_LANG2          0x0002
 #define V4L2_TUNER_MODE_SAP            0x0002
 #define V4L2_TUNER_MODE_LANG1          0x0003
+#define V4L2_TUNER_MODE_LANG1_LANG2    0x0004
 
 struct v4l2_frequency
 {
@@ -949,13 +964,15 @@ struct v4l2_sliced_vbi_format
        __u32   reserved[2];            /* must be zero */
 };
 
-/* Teletext WST, defined on ITU-R BT.653-2 */
+/* Teletext World System Teletext
+   (WST), defined on ITU-R BT.653-2 */
 #define V4L2_SLICED_TELETEXT_PAL_B      (0x000001)
 #define V4L2_SLICED_TELETEXT_PAL_C      (0x000002)
 #define V4L2_SLICED_TELETEXT_NTSC_B     (0x000010)
 #define V4L2_SLICED_TELETEXT_SECAM      (0x000020)
 
-/* Teletext NABTS, defined on ITU-R BT.653-2 */
+/* Teletext North American Broadcast Teletext Specification
+   (NABTS), defined on ITU-R BT.653-2 */
 #define V4L2_SLICED_TELETEXT_NTSC_C     (0x000040)
 #define V4L2_SLICED_TELETEXT_NTSC_D     (0x000080)
 
@@ -976,8 +993,24 @@ struct v4l2_sliced_vbi_format
 #define V4l2_SLICED_VITC_625           (0x010000)
 #define V4l2_SLICED_VITC_525           (0x020000)
 
-/* Compat macro - Should be removed for 2.6.18 */
-#define V4L2_SLICED_TELETEXT_B V4L2_SLICED_TELETEXT_PAL_B
+#define V4L2_SLICED_TELETEXT_B         (V4L2_SLICED_TELETEXT_PAL_B  |\
+                                        V4L2_SLICED_TELETEXT_NTSC_B)
+
+#define V4L2_SLICED_TELETEXT           (V4L2_SLICED_TELETEXT_PAL_B  |\
+                                        V4L2_SLICED_TELETEXT_PAL_C  |\
+                                        V4L2_SLICED_TELETEXT_SECAM  |\
+                                        V4L2_SLICED_TELETEXT_NTSC_B |\
+                                        V4L2_SLICED_TELETEXT_NTSC_C |\
+                                        V4L2_SLICED_TELETEXT_NTSC_D)
+
+#define V4L2_SLICED_CAPTION            (V4L2_SLICED_CAPTION_525     |\
+                                        V4L2_SLICED_CAPTION_625)
+
+#define V4L2_SLICED_WSS                        (V4L2_SLICED_WSS_525         |\
+                                        V4L2_SLICED_WSS_625)
+
+#define V4L2_SLICED_VITC               (V4L2_SLICED_VITC_525        |\
+                                        V4L2_SLICED_VITC_625)
 
 #define V4L2_SLICED_VBI_525             (V4L2_SLICED_TELETEXT_NTSC_B |\
                                         V4L2_SLICED_TELETEXT_NTSC_C |\