diff options
author | Hans Verkuil <hverkuil@xs4all.nl> | 2006-06-18 21:54:20 +0200 |
---|---|---|
committer | Hans Verkuil <hverkuil@xs4all.nl> | 2006-06-18 21:54:20 +0200 |
commit | 6cdc5db5eecbf7385e190aab3718ccfbdc981077 (patch) | |
tree | ac296b792c552eb9ba19184c7cf26617b34fb706 | |
parent | 523686db1e20dffeb8509a4092cb3d8f425ef930 (diff) | |
download | mediapointer-dvb-s2-6cdc5db5eecbf7385e190aab3718ccfbdc981077.tar.gz mediapointer-dvb-s2-6cdc5db5eecbf7385e190aab3718ccfbdc981077.tar.bz2 |
Put old MPEGCOMP API under #if __KERNEL__ and issue warnings when used.
From: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
-rw-r--r-- | linux/drivers/media/video/cx88/cx88-blackbird.c | 4 | ||||
-rw-r--r-- | linux/drivers/media/video/saa7134/saa7134-empress.c | 4 | ||||
-rw-r--r-- | linux/drivers/media/video/videodev.c | 1 | ||||
-rw-r--r-- | linux/include/linux/videodev2.h | 9 |
4 files changed, 14 insertions, 4 deletions
diff --git a/linux/drivers/media/video/cx88/cx88-blackbird.c b/linux/drivers/media/video/cx88/cx88-blackbird.c index cad6f4a92..1a86d337f 100644 --- a/linux/drivers/media/video/cx88/cx88-blackbird.c +++ b/linux/drivers/media/video/cx88/cx88-blackbird.c @@ -838,10 +838,14 @@ static int mpeg_do_ioctl(struct inode *inode, struct file *file, { struct v4l2_mpeg_compression *f = arg; + printk(KERN_WARNING "VIDIOC_G_MPEGCOMP is obsolete. " + "Replace with VIDIOC_G_EXT_CTRLS!"); memcpy(f,&default_mpeg_params,sizeof(*f)); return 0; } case VIDIOC_S_MPEGCOMP: + printk(KERN_WARNING "VIDIOC_S_MPEGCOMP is obsolete. " + "Replace with VIDIOC_S_EXT_CTRLS!"); return 0; case VIDIOC_G_EXT_CTRLS: { diff --git a/linux/drivers/media/video/saa7134/saa7134-empress.c b/linux/drivers/media/video/saa7134/saa7134-empress.c index 46c5fdaf7..690891588 100644 --- a/linux/drivers/media/video/saa7134/saa7134-empress.c +++ b/linux/drivers/media/video/saa7134/saa7134-empress.c @@ -291,10 +291,14 @@ static int ts_do_ioctl(struct inode *inode, struct file *file, return saa7134_common_ioctl(dev, cmd, arg); case VIDIOC_S_MPEGCOMP: + printk(KERN_WARNING "VIDIOC_S_MPEGCOMP is obsolete. " + "Replace with VIDIOC_S_EXT_CTRLS!"); saa7134_i2c_call_clients(dev, VIDIOC_S_MPEGCOMP, arg); ts_init_encoder(dev); return 0; case VIDIOC_G_MPEGCOMP: + printk(KERN_WARNING "VIDIOC_G_MPEGCOMP is obsolete. " + "Replace with VIDIOC_G_EXT_CTRLS!"); saa7134_i2c_call_clients(dev, VIDIOC_G_MPEGCOMP, arg); return 0; case VIDIOC_S_EXT_CTRLS: diff --git a/linux/drivers/media/video/videodev.c b/linux/drivers/media/video/videodev.c index 8eaf1b8ca..342ccf3ff 100644 --- a/linux/drivers/media/video/videodev.c +++ b/linux/drivers/media/video/videodev.c @@ -1235,6 +1235,7 @@ static int __video_do_ioctl(struct inode *inode, struct file *file, case VIDIOC_G_MPEGCOMP: { struct v4l2_mpeg_compression *p=arg; + /*FIXME: Several fields not shown */ if (!vfd->vidioc_g_mpegcomp) break; diff --git a/linux/include/linux/videodev2.h b/linux/include/linux/videodev2.h index d095481c0..3512e05f7 100644 --- a/linux/include/linux/videodev2.h +++ b/linux/include/linux/videodev2.h @@ -306,12 +306,13 @@ struct v4l2_timecode #define V4L2_TC_USERBITS_8BITCHARS 0x0008 /* The above is based on SMPTE timecodes */ -#if 1 +#ifdef __KERNEL__ /* * M P E G C O M P R E S S I O N P A R A M E T E R S * - * ### WARNING: this is still work-in-progress right now, most likely - * ### there will be some incompatible changes. + * ### WARNING: This experimental MPEG compression API is obsolete. + * ### It is replaced by the MPEG controls API. + * ### This old API will disappear in the near future! * */ enum v4l2_bitrate_mode { @@ -1253,7 +1254,7 @@ struct v4l2_streamparm #define VIDIOC_ENUM_FMT _IOWR ('V', 2, struct v4l2_fmtdesc) #define VIDIOC_G_FMT _IOWR ('V', 4, struct v4l2_format) #define VIDIOC_S_FMT _IOWR ('V', 5, struct v4l2_format) -#if 1 /* experimental */ +#ifdef __KERNEL__ #define VIDIOC_G_MPEGCOMP _IOR ('V', 6, struct v4l2_mpeg_compression) #define VIDIOC_S_MPEGCOMP _IOW ('V', 7, struct v4l2_mpeg_compression) #endif |