aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video/em28xx
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@redhat.com>2011-06-24 13:45:49 -0400
committerMauro Carvalho Chehab <mchehab@redhat.com>2011-07-27 16:53:12 -0400
commit1990d50b58bef127a647005fdcada6d07081d3ef (patch)
tree094d27aa88e25b9f48f505068147eeedf2a6d3df /drivers/media/video/em28xx
parentd35ebf9558e692299b764163d61420fe5f526c02 (diff)
[media] Stop using linux/version.h on most video drivers
All the modified drivers didn't have any version increment since Jan, 1 2011. Several of them didn't have any version increment for a long time, even having new features and important bug fixes happening. As we're now filling the QUERYCAP version with the current Kernel Release, we don't need to maintain a per-driver version control anymore. So, let's just use the default. In order to preserve the Kernel module version history, a KERNEL_VERSION() macro were added to all modified drivers, and the extraver number were incremented. I opted to preserve the per-driver version control to a few pwc, pvrusb2, s2255, s5p-fimc and sh_vou. A few drivers are still using the legacy way to handle ioctl's. So, we can't do such change on them, otherwise, they'll break. Those are: uvc, et61x251 and sn9c102. The rationale is that the per-driver version control seems to be actively maintained on those. Yet, I think that the better for them would be to just use the default version numbering, instead of doing that by themselves. While here, removed a few uneeded include linux/version.h Acked-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video/em28xx')
-rw-r--r--drivers/media/video/em28xx/em28xx-video.c14
1 files changed, 5 insertions, 9 deletions
diff --git a/drivers/media/video/em28xx/em28xx-video.c b/drivers/media/video/em28xx/em28xx-video.c
index 7b6461d2d1ff..d176dc0394e2 100644
--- a/drivers/media/video/em28xx/em28xx-video.c
+++ b/drivers/media/video/em28xx/em28xx-video.c
@@ -32,7 +32,6 @@
32#include <linux/bitmap.h> 32#include <linux/bitmap.h>
33#include <linux/usb.h> 33#include <linux/usb.h>
34#include <linux/i2c.h> 34#include <linux/i2c.h>
35#include <linux/version.h>
36#include <linux/mm.h> 35#include <linux/mm.h>
37#include <linux/mutex.h> 36#include <linux/mutex.h>
38#include <linux/slab.h> 37#include <linux/slab.h>
@@ -50,7 +49,8 @@
50 "Sascha Sommer <saschasommer@freenet.de>" 49 "Sascha Sommer <saschasommer@freenet.de>"
51 50
52#define DRIVER_DESC "Empia em28xx based USB video device driver" 51#define DRIVER_DESC "Empia em28xx based USB video device driver"
53#define EM28XX_VERSION_CODE KERNEL_VERSION(0, 1, 2) 52
53#define EM28XX_VERSION "0.1.3"
54 54
55#define em28xx_videodbg(fmt, arg...) do {\ 55#define em28xx_videodbg(fmt, arg...) do {\
56 if (video_debug) \ 56 if (video_debug) \
@@ -72,6 +72,7 @@ do {\
72MODULE_AUTHOR(DRIVER_AUTHOR); 72MODULE_AUTHOR(DRIVER_AUTHOR);
73MODULE_DESCRIPTION(DRIVER_DESC); 73MODULE_DESCRIPTION(DRIVER_DESC);
74MODULE_LICENSE("GPL"); 74MODULE_LICENSE("GPL");
75MODULE_VERSION(EM28XX_VERSION);
75 76
76static unsigned int video_nr[] = {[0 ... (EM28XX_MAXBOARDS - 1)] = UNSET }; 77static unsigned int video_nr[] = {[0 ... (EM28XX_MAXBOARDS - 1)] = UNSET };
77static unsigned int vbi_nr[] = {[0 ... (EM28XX_MAXBOARDS - 1)] = UNSET }; 78static unsigned int vbi_nr[] = {[0 ... (EM28XX_MAXBOARDS - 1)] = UNSET };
@@ -1757,8 +1758,6 @@ static int vidioc_querycap(struct file *file, void *priv,
1757 strlcpy(cap->card, em28xx_boards[dev->model].name, sizeof(cap->card)); 1758 strlcpy(cap->card, em28xx_boards[dev->model].name, sizeof(cap->card));
1758 usb_make_path(dev->udev, cap->bus_info, sizeof(cap->bus_info)); 1759 usb_make_path(dev->udev, cap->bus_info, sizeof(cap->bus_info));
1759 1760
1760 cap->version = EM28XX_VERSION_CODE;
1761
1762 cap->capabilities = 1761 cap->capabilities =
1763 V4L2_CAP_SLICED_VBI_CAPTURE | 1762 V4L2_CAP_SLICED_VBI_CAPTURE |
1764 V4L2_CAP_VIDEO_CAPTURE | 1763 V4L2_CAP_VIDEO_CAPTURE |
@@ -1976,7 +1975,6 @@ static int radio_querycap(struct file *file, void *priv,
1976 strlcpy(cap->card, em28xx_boards[dev->model].name, sizeof(cap->card)); 1975 strlcpy(cap->card, em28xx_boards[dev->model].name, sizeof(cap->card));
1977 usb_make_path(dev->udev, cap->bus_info, sizeof(cap->bus_info)); 1976 usb_make_path(dev->udev, cap->bus_info, sizeof(cap->bus_info));
1978 1977
1979 cap->version = EM28XX_VERSION_CODE;
1980 cap->capabilities = V4L2_CAP_TUNER; 1978 cap->capabilities = V4L2_CAP_TUNER;
1981 return 0; 1979 return 0;
1982} 1980}
@@ -2450,10 +2448,8 @@ int em28xx_register_analog_devices(struct em28xx *dev)
2450 u8 val; 2448 u8 val;
2451 int ret; 2449 int ret;
2452 2450
2453 printk(KERN_INFO "%s: v4l2 driver version %d.%d.%d\n", 2451 printk(KERN_INFO "%s: v4l2 driver version %s\n",
2454 dev->name, 2452 dev->name, EM28XX_VERSION);
2455 (EM28XX_VERSION_CODE >> 16) & 0xff,
2456 (EM28XX_VERSION_CODE >> 8) & 0xff, EM28XX_VERSION_CODE & 0xff);
2457 2453
2458 /* set default norm */ 2454 /* set default norm */
2459 dev->norm = em28xx_video_template.current_norm; 2455 dev->norm = em28xx_video_template.current_norm;