patch-2.4.23 linux-2.4.23/drivers/media/video/bttv-if.c

Next file: linux-2.4.23/drivers/media/video/bttvp.h
Previous file: linux-2.4.23/drivers/media/video/bttv-driver.c
Back to the patch index
Back to the overall index

diff -urN linux-2.4.22/drivers/media/video/bttv-if.c linux-2.4.23/drivers/media/video/bttv-if.c
@@ -190,6 +190,7 @@
 	return state;
 }
 
+#ifndef I2C_PEC
 static void bttv_inc_use(struct i2c_adapter *adap)
 {
 	MOD_INC_USE_COUNT;
@@ -199,6 +200,7 @@
 {
 	MOD_DEC_USE_COUNT;
 }
+#endif
 
 static int attach_inform(struct i2c_client *client)
 {
@@ -241,8 +243,15 @@
 };
 
 static struct i2c_adapter bttv_i2c_adap_template = {
+#ifdef I2C_PEC
+	.owner             = THIS_MODULE,
+#else
 	.inc_use           = bttv_inc_use,
 	.dec_use           = bttv_dec_use,
+#endif
+#ifdef I2C_ADAP_CLASS_TV_ANALOG
+	.class             = I2C_ADAP_CLASS_TV_ANALOG,
+#endif
 	I2C_DEVNAME("bt848"),
 	.id                = I2C_HW_B_BT848,
 	.client_register   = attach_inform,

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)