summaryrefslogtreecommitdiff
path: root/linux/drivers/media/video/tda9875.c
diff options
context:
space:
mode:
Diffstat (limited to 'linux/drivers/media/video/tda9875.c')
-rw-r--r--linux/drivers/media/video/tda9875.c29
1 files changed, 2 insertions, 27 deletions
diff --git a/linux/drivers/media/video/tda9875.c b/linux/drivers/media/video/tda9875.c
index 340ea2300..86e721656 100644
--- a/linux/drivers/media/video/tda9875.c
+++ b/linux/drivers/media/video/tda9875.c
@@ -31,11 +31,6 @@
#include <linux/init.h>
#include "compat.h"
-#if LINUX_VERSION_CODE < KERNEL_VERSION(2,5,0)
-#include "id.h"
-#include "i2c-compat.h"
-#endif
-
#include <media/i2c-addr.h>
static int debug; /* insmod parameter */
@@ -47,9 +42,7 @@ static unsigned short normal_i2c[] = {
I2C_ADDR_TDA9875 >> 1,
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;
/* This is a superset of the TDA9875 */
@@ -244,12 +237,7 @@ static int tda9875_checkit(struct i2c_adapter *adap, int addr)
return(0);
}
-#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,0)
static int tda9875_attach(struct i2c_adapter *adap, int addr, int kind)
-#else
-static int tda9875_attach(struct i2c_adapter *adap, int addr,
- unsigned short flags, int kind)
-#endif
{
struct tda9875 *t;
struct i2c_client *client;
@@ -271,9 +259,6 @@ static int tda9875_attach(struct i2c_adapter *adap, int addr,
}
do_tda9875_init(client);
-#if LINUX_VERSION_CODE < KERNEL_VERSION(2,5,0)
- MOD_INC_USE_COUNT;
-#endif
printk(KERN_INFO "tda9875: init\n");
i2c_attach_client(client);
@@ -282,13 +267,8 @@ static int tda9875_attach(struct i2c_adapter *adap, int addr,
static int tda9875_probe(struct i2c_adapter *adap)
{
-#ifdef I2C_CLASS_TV_ANALOG
if (adap->class & I2C_CLASS_TV_ANALOG)
return i2c_probe(adap, &addr_data, tda9875_attach);
-#else
- if (adap->id == I2C_HW_B_BT848)
- return i2c_probe(adap, &addr_data, tda9875_attach);
-#endif
return 0;
}
@@ -300,9 +280,6 @@ static int tda9875_detach(struct i2c_client *client)
i2c_detach_client(client);
kfree(t);
-#if LINUX_VERSION_CODE < KERNEL_VERSION(2,5,0)
- MOD_DEC_USE_COUNT;
-#endif
return 0;
}
@@ -456,10 +433,8 @@ static int tda9875_command(struct i2c_client *client,
static struct i2c_driver driver = {
-#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,0))&&(LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15))
+#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15)
.owner = THIS_MODULE,
-#endif
-#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15)
.name = "tda9875",
.flags = I2C_DF_NOTIFY,
#else