aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video/cpia2
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/cpia2
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/cpia2')
-rw-r--r--drivers/media/video/cpia2/cpia2.h5
-rw-r--r--drivers/media/video/cpia2/cpia2_v4l.c12
2 files changed, 4 insertions, 13 deletions
diff --git a/drivers/media/video/cpia2/cpia2.h b/drivers/media/video/cpia2/cpia2.h
index 6d6d1843791c..ab252188981b 100644
--- a/drivers/media/video/cpia2/cpia2.h
+++ b/drivers/media/video/cpia2/cpia2.h
@@ -31,7 +31,6 @@
31#ifndef __CPIA2_H__ 31#ifndef __CPIA2_H__
32#define __CPIA2_H__ 32#define __CPIA2_H__
33 33
34#include <linux/version.h>
35#include <linux/videodev2.h> 34#include <linux/videodev2.h>
36#include <media/v4l2-common.h> 35#include <media/v4l2-common.h>
37#include <linux/usb.h> 36#include <linux/usb.h>
@@ -43,10 +42,6 @@
43/* define for verbose debug output */ 42/* define for verbose debug output */
44//#define _CPIA2_DEBUG_ 43//#define _CPIA2_DEBUG_
45 44
46#define CPIA2_MAJ_VER 3
47#define CPIA2_MIN_VER 0
48#define CPIA2_PATCH_VER 0
49
50/*** 45/***
51 * Image defines 46 * Image defines
52 ***/ 47 ***/
diff --git a/drivers/media/video/cpia2/cpia2_v4l.c b/drivers/media/video/cpia2/cpia2_v4l.c
index 40eb6326e48a..077eb1db80a1 100644
--- a/drivers/media/video/cpia2/cpia2_v4l.c
+++ b/drivers/media/video/cpia2/cpia2_v4l.c
@@ -29,8 +29,7 @@
29 * Alan Cox <alan@lxorguk.ukuu.org.uk> 29 * Alan Cox <alan@lxorguk.ukuu.org.uk>
30 ****************************************************************************/ 30 ****************************************************************************/
31 31
32#include <linux/version.h> 32#define CPIA_VERSION "3.0.1"
33
34 33
35#include <linux/module.h> 34#include <linux/module.h>
36#include <linux/time.h> 35#include <linux/time.h>
@@ -80,6 +79,7 @@ MODULE_AUTHOR("Steve Miller (STMicroelectronics) <steve.miller@st.com>");
80MODULE_DESCRIPTION("V4L-driver for STMicroelectronics CPiA2 based cameras"); 79MODULE_DESCRIPTION("V4L-driver for STMicroelectronics CPiA2 based cameras");
81MODULE_SUPPORTED_DEVICE("video"); 80MODULE_SUPPORTED_DEVICE("video");
82MODULE_LICENSE("GPL"); 81MODULE_LICENSE("GPL");
82MODULE_VERSION(CPIA_VERSION);
83 83
84#define ABOUT "V4L-Driver for Vision CPiA2 based cameras" 84#define ABOUT "V4L-Driver for Vision CPiA2 based cameras"
85 85
@@ -465,9 +465,6 @@ static int cpia2_querycap(struct file *file, void *fh, struct v4l2_capability *v
465 if (usb_make_path(cam->dev, vc->bus_info, sizeof(vc->bus_info)) <0) 465 if (usb_make_path(cam->dev, vc->bus_info, sizeof(vc->bus_info)) <0)
466 memset(vc->bus_info,0, sizeof(vc->bus_info)); 466 memset(vc->bus_info,0, sizeof(vc->bus_info));
467 467
468 vc->version = KERNEL_VERSION(CPIA2_MAJ_VER, CPIA2_MIN_VER,
469 CPIA2_PATCH_VER);
470
471 vc->capabilities = V4L2_CAP_VIDEO_CAPTURE | 468 vc->capabilities = V4L2_CAP_VIDEO_CAPTURE |
472 V4L2_CAP_READWRITE | 469 V4L2_CAP_READWRITE |
473 V4L2_CAP_STREAMING; 470 V4L2_CAP_STREAMING;
@@ -1558,8 +1555,8 @@ static void __init check_parameters(void)
1558 *****************************************************************************/ 1555 *****************************************************************************/
1559static int __init cpia2_init(void) 1556static int __init cpia2_init(void)
1560{ 1557{
1561 LOG("%s v%d.%d.%d\n", 1558 LOG("%s v%s\n",
1562 ABOUT, CPIA2_MAJ_VER, CPIA2_MIN_VER, CPIA2_PATCH_VER); 1559 ABOUT, CPIA_VERSION);
1563 check_parameters(); 1560 check_parameters();
1564 cpia2_usb_init(); 1561 cpia2_usb_init();
1565 return 0; 1562 return 0;
@@ -1579,4 +1576,3 @@ static void __exit cpia2_exit(void)
1579 1576
1580module_init(cpia2_init); 1577module_init(cpia2_init);
1581module_exit(cpia2_exit); 1578module_exit(cpia2_exit);
1582