summaryrefslogtreecommitdiff
path: root/linux/include
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <devnull@localhost>2006-01-09 17:17:32 +0000
committerMauro Carvalho Chehab <devnull@localhost>2006-01-09 17:17:32 +0000
commit6807eba35cc91e109fed1df6038c424496cf2add (patch)
tree475351eb821b9e5a741faa5ba2f97e27cbf2e857 /linux/include
parent1faa3dcb3917ba99177697e1b8b4473e388744f8 (diff)
downloadmediapointer-dvb-s2-6807eba35cc91e109fed1df6038c424496cf2add.tar.gz
mediapointer-dvb-s2-6807eba35cc91e109fed1df6038c424496cf2add.tar.bz2
Several i2C cleanups to compile on both current linux and kernels >2.6.15
kernel-sync Signed-off-by: Mauro Carvalho Chehab <mchehab@brturbo.com.br>
Diffstat (limited to 'linux/include')
-rw-r--r--linux/include/linux/i2c-id.h20
-rw-r--r--linux/include/media/saa7146.h10
2 files changed, 10 insertions, 20 deletions
diff --git a/linux/include/linux/i2c-id.h b/linux/include/linux/i2c-id.h
index c4564a283..6ff2d3658 100644
--- a/linux/include/linux/i2c-id.h
+++ b/linux/include/linux/i2c-id.h
@@ -25,12 +25,6 @@
/*
* ---- Driver types -----------------------------------------------------
- * device id name + number function description, i2c address(es)
- *
- * Range 1000-1999 range is defined in sensors/sensors.h
- * Range 0x100 - 0x1ff is for V4L2 Common Components
- * Range 0xf000 - 0xffff is reserved for local experimentation, and should
- * never be used in official drivers
*/
#define I2C_DRIVERID_MSP3400 1
@@ -111,13 +105,7 @@
#define I2C_DRIVERID_INFRARED 75 /* I2C InfraRed on Video boards */
#define I2C_DRIVERID_TVP5150 76 /* TVP5150 video decoder */
-#define I2C_DRIVERID_EXP0 0xF0 /* experimental use id's */
-#define I2C_DRIVERID_EXP1 0xF1
-#define I2C_DRIVERID_EXP2 0xF2
-#define I2C_DRIVERID_EXP3 0xF3
-
#define I2C_DRIVERID_I2CDEV 900
-#define I2C_DRIVERID_I2CPROC 901
#define I2C_DRIVERID_ARP 902 /* SMBus ARP Client */
#define I2C_DRIVERID_ALERT 903 /* SMBus Alert Responder Client */
@@ -132,15 +120,12 @@
#define I2C_DRIVERID_ADM1021 1008
#define I2C_DRIVERID_ADM9240 1009
#define I2C_DRIVERID_LTC1710 1010
-#define I2C_DRIVERID_SIS5595 1011
#define I2C_DRIVERID_ICSPLL 1012
#define I2C_DRIVERID_BT869 1013
#define I2C_DRIVERID_MAXILIFE 1014
#define I2C_DRIVERID_MATORB 1015
#define I2C_DRIVERID_GL520 1016
#define I2C_DRIVERID_THMC50 1017
-#define I2C_DRIVERID_DDCMON 1018
-#define I2C_DRIVERID_VIA686A 1019
#define I2C_DRIVERID_ADM1025 1020
#define I2C_DRIVERID_LM87 1021
#define I2C_DRIVERID_PCF8574 1022
@@ -152,21 +137,16 @@
#define I2C_DRIVERID_FSCPOS 1028
#define I2C_DRIVERID_FSCSCY 1029
#define I2C_DRIVERID_PCF8591 1030
-#define I2C_DRIVERID_SMSC47M1 1031
-#define I2C_DRIVERID_VT1211 1032
#define I2C_DRIVERID_LM92 1033
-#define I2C_DRIVERID_VT8231 1034
#define I2C_DRIVERID_SMARTBATT 1035
#define I2C_DRIVERID_BMCSENSORS 1036
#define I2C_DRIVERID_FS451 1037
-#define I2C_DRIVERID_W83627HF 1038
#define I2C_DRIVERID_LM85 1039
#define I2C_DRIVERID_LM83 1040
#define I2C_DRIVERID_LM90 1042
#define I2C_DRIVERID_ASB100 1043
#define I2C_DRIVERID_FSCHER 1046
#define I2C_DRIVERID_W83L785TS 1047
-#define I2C_DRIVERID_SMSC47B397 1050
/*
* ---- Adapter types ----------------------------------------------------
diff --git a/linux/include/media/saa7146.h b/linux/include/media/saa7146.h
index e5be2b9b8..760ae6324 100644
--- a/linux/include/media/saa7146.h
+++ b/linux/include/media/saa7146.h
@@ -13,6 +13,7 @@
#include <linux/stringify.h>
#include <linux/vmalloc.h> /* for vmalloc() */
#include <linux/mm.h> /* for vmalloc_to_page() */
+#include "compat.h"
#define SAA7146_VERSION_CODE 0x000500 /* 0.5.0 */
@@ -21,14 +22,23 @@
extern unsigned int saa7146_debug;
+#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15)
//#define DEBUG_PROLOG printk("(0x%08x)(0x%08x) %s: %s(): ",(dev==0?-1:(dev->mem==0?-1:saa7146_read(dev,RPS_ADDR0))),(dev==0?-1:(dev->mem==0?-1:saa7146_read(dev,IER))),__stringify(KBUILD_MODNAME),__FUNCTION__)
+#else
+//#define DEBUG_PROLOG printk("(0x%08x)(0x%08x) %s: %s(): ",(dev==0?-1:(dev->mem==0?-1:saa7146_read(dev,RPS_ADDR0))),(dev==0?-1:(dev->mem==0?-1:saa7146_read(dev,IER))),KBUILD_MODNAME,__FUNCTION__)
+#endif
#ifndef DEBUG_VARIABLE
#define DEBUG_VARIABLE saa7146_debug
#endif
+#if LINUX_VERSION_CODE <= KERNEL_VERSION(2,6,15)
#define DEBUG_PROLOG printk("%s: %s(): ",__stringify(KBUILD_MODNAME),__FUNCTION__)
#define INFO(x) { printk("%s: ",__stringify(KBUILD_MODNAME)); printk x; }
+#else
+#define DEBUG_PROLOG printk("%s: %s(): ",KBUILD_MODNAME,__FUNCTION__)
+#define INFO(x) { printk("%s: ",KBUILD_MODNAME); printk x; }
+#endif
#define ERR(x) { DEBUG_PROLOG; printk x; }