summaryrefslogtreecommitdiff
path: root/linux/drivers/media/video/tvp5150.c
diff options
context:
space:
mode:
Diffstat (limited to 'linux/drivers/media/video/tvp5150.c')
-rw-r--r--linux/drivers/media/video/tvp5150.c44
1 files changed, 0 insertions, 44 deletions
diff --git a/linux/drivers/media/video/tvp5150.c b/linux/drivers/media/video/tvp5150.c
index 7dc6623cc..6ac63245d 100644
--- a/linux/drivers/media/video/tvp5150.c
+++ b/linux/drivers/media/video/tvp5150.c
@@ -12,12 +12,6 @@
#include <linux/video_decoder.h>
#include <media/v4l2-common.h>
#include <media/tvp5150.h>
-#if LINUX_VERSION_CODE < KERNEL_VERSION(2,5,0)
-#include <linux/module.h>
-#include <linux/delay.h>
-#include <linux/slab.h>
-#include "i2c-compat.h"
-#endif
#include "tvp5150_reg.h"
@@ -32,30 +26,12 @@ static unsigned short normal_i2c[] = {
I2C_CLIENT_END
};
-#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,13)
-static unsigned short normal_i2c_range[] = { I2C_CLIENT_END };
-#endif
I2C_CLIENT_INSMOD;
static int debug;
module_param(debug, int, 0);
MODULE_PARM_DESC(debug, "Debug level (0-1)");
-#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15)
-#define tvp5150_err(fmt, arg...) do { \
- printk(KERN_INFO "%s %d-%04x: " fmt, c->driver->name, \
- i2c_adapter_id(c->adapter), c->addr , ## arg); } while (0)
-#define tvp5150_info(fmt, arg...) do { \
- printk(KERN_INFO "%s %d-%04x: " fmt, c->driver->name, \
- i2c_adapter_id(c->adapter), c->addr , ## arg); } while (0)
-#define tvp5150_dbg(num, fmt, arg...) \
- do { \
- if (debug >= num) \
- printk(KERN_DEBUG "%s debug %d-%04x: " fmt,\
- c->driver->name, \
- i2c_adapter_id(c->adapter), \
- c->addr , ## arg); } while (0)
-#else
#define tvp5150_err(fmt, arg...) do { \
printk(KERN_ERR "%s %d-%04x: " fmt, c->driver->driver.name, \
i2c_adapter_id(c->adapter), c->addr , ## arg); } while (0)
@@ -69,7 +45,6 @@ MODULE_PARM_DESC(debug, "Debug level (0-1)");
c->driver->driver.name, \
i2c_adapter_id(c->adapter), \
c->addr , ## arg); } while (0)
-#endif
/* supported controls */
static struct v4l2_queryctrl tvp5150_qctrl[] = {
@@ -1142,19 +1117,11 @@ static struct i2c_driver driver;
static struct i2c_client client_template = {
.name = "(unset)",
-#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15)
- .flags = I2C_CLIENT_ALLOW_USE,
-#endif
.driver = &driver,
};
-#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,0)
static int tvp5150_detect_client(struct i2c_adapter *adapter,
int address, int kind)
-#else
-static int tvp5150_detect_client(struct i2c_adapter *adapter,
- int address, unsigned short flags, int kind)
-#endif
{
struct i2c_client *c;
struct tvp5150 *core;
@@ -1204,9 +1171,6 @@ static int tvp5150_detect_client(struct i2c_adapter *adapter,
if (debug > 1)
dump_reg(c);
-#if LINUX_VERSION_CODE < KERNEL_VERSION(2,5,0)
- MOD_INC_USE_COUNT;
-#endif
return 0;
}
@@ -1242,17 +1206,9 @@ static int tvp5150_detach_client(struct i2c_client *c)
/* ----------------------------------------------------------------------- */
static struct i2c_driver driver = {
-#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,0))&&(LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15))
- .owner = THIS_MODULE,
-#endif
-#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15)
- .name = "tvp5150",
- .flags = I2C_DF_NOTIFY,
-#else
.driver = {
.name = "tvp5150",
},
-#endif
.id = I2C_DRIVERID_TVP5150,
.attach_adapter = tvp5150_attach_adapter,