summaryrefslogtreecommitdiff
path: root/linux
diff options
context:
space:
mode:
Diffstat (limited to 'linux')
-rw-r--r--linux/drivers/media/video/bt8xx/bttv-driver.c11
-rw-r--r--linux/include/media/v4l2-dev.h5
2 files changed, 4 insertions, 12 deletions
diff --git a/linux/drivers/media/video/bt8xx/bttv-driver.c b/linux/drivers/media/video/bt8xx/bttv-driver.c
index 0903a3803..a43764dea 100644
--- a/linux/drivers/media/video/bt8xx/bttv-driver.c
+++ b/linux/drivers/media/video/bt8xx/bttv-driver.c
@@ -3942,10 +3942,6 @@ static void bttv_unregister_video(struct bttv *btv)
/* register video4linux devices */
static int __devinit bttv_register_video(struct bttv *btv)
{
-#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,17)
- int ret;
-#endif
-
if (no_overlay <= 0) {
bttv_video_template.type |= VID_TYPE_OVERLAY;
} else {
@@ -3960,17 +3956,10 @@ static int __devinit bttv_register_video(struct bttv *btv)
goto err;
printk(KERN_INFO "bttv%d: registered device video%d\n",
btv->c.nr,btv->video_dev->minor & 0x1f);
-#if LINUX_VERSION_CODE > KERNEL_VERSION(2,6,17)
- ret = video_device_create_file(btv->video_dev, &class_device_attr_card);
- if (ret < 0)
- printk(KERN_WARNING "bttv: video_device_create_file error: "
- "%d\n", ret);
-#else
#if LINUX_VERSION_CODE > KERNEL_VERSION(2,5,0)
video_device_create_file(btv->video_dev, &class_device_attr_card);
#endif
-#endif
/* vbi */
btv->vbi_dev = vdev_init(btv, &bttv_vbi_template, "vbi");
diff --git a/linux/include/media/v4l2-dev.h b/linux/include/media/v4l2-dev.h
index b3b196b88..171a63f65 100644
--- a/linux/include/media/v4l2-dev.h
+++ b/linux/include/media/v4l2-dev.h
@@ -380,7 +380,10 @@ static inline int
video_device_create_file(struct video_device *vfd,
struct class_device_attribute *attr)
{
- return class_device_create_file(&vfd->class_dev, attr);
+ int ret = class_device_create_file(&vfd->class_dev, attr);
+ if (ret < 0)
+ printk(KERN_WARNING "%s error: %d\n", __FUNCTION__, ret);
+ return ret;
}
static inline void
video_device_remove_file(struct video_device *vfd,