aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video/usbvision/usbvision-i2c.c
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@infradead.org>2006-12-09 09:41:59 -0500
committerMauro Carvalho Chehab <mchehab@infradead.org>2006-12-10 06:22:53 -0500
commita1ed551cdb4f29157466340760fde68bcda704a9 (patch)
tree9e749237583521420175e485522de346db4f468d /drivers/media/video/usbvision/usbvision-i2c.c
parent7ca659e3c1c3dd67073751385ae3bd25b27526bb (diff)
V4L/DVB (4941): Remove LINUX_VERSION_CODE and fix identations
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers/media/video/usbvision/usbvision-i2c.c')
-rw-r--r--drivers/media/video/usbvision/usbvision-i2c.c14
1 files changed, 5 insertions, 9 deletions
diff --git a/drivers/media/video/usbvision/usbvision-i2c.c b/drivers/media/video/usbvision/usbvision-i2c.c
index 2de74e48cbe5..92bf9a1f1e2c 100644
--- a/drivers/media/video/usbvision/usbvision-i2c.c
+++ b/drivers/media/video/usbvision/usbvision-i2c.c
@@ -29,7 +29,7 @@
29#include <linux/delay.h> 29#include <linux/delay.h>
30#include <linux/slab.h> 30#include <linux/slab.h>
31#include <linux/version.h> 31#include <linux/version.h>
32 #include <linux/utsname.h> 32#include <linux/utsname.h>
33#include <linux/init.h> 33#include <linux/init.h>
34#include <asm/uaccess.h> 34#include <asm/uaccess.h>
35#include <linux/ioport.h> 35#include <linux/ioport.h>
@@ -350,13 +350,9 @@ static int detach_inform(struct i2c_client *client)
350{ 350{
351 struct usb_usbvision *usbvision; 351 struct usb_usbvision *usbvision;
352 352
353 #if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,0) 353 usbvision = (struct usb_usbvision *)i2c_get_adapdata(client->adapter);
354 usbvision = (struct usb_usbvision *)client->adapter->data;
355 #else
356 usbvision = (struct usb_usbvision *)i2c_get_adapdata(client->adapter);
357 #endif
358 354
359 PDEBUG(DBG_I2C,"usbvision[%d] detaches %s", usbvision->nr, client->name); 355 PDEBUG(DBG_I2C,"usbvision[%d] detaches %s", usbvision->nr, client->name);
360 return 0; 356 return 0;
361} 357}
362 358
@@ -548,9 +544,9 @@ static struct i2c_adapter i2c_adap_template = {
548 .algo_data = NULL, 544 .algo_data = NULL,
549 .client_register = attach_inform, 545 .client_register = attach_inform,
550 .client_unregister = detach_inform, 546 .client_unregister = detach_inform,
551#if defined (I2C_ADAP_CLASS_TV_ANALOG) 547#ifdef I2C_ADAP_CLASS_TV_ANALOG
552 .class = I2C_ADAP_CLASS_TV_ANALOG, 548 .class = I2C_ADAP_CLASS_TV_ANALOG,
553#elif defined (I2C_CLASS_TV_ANALOG) 549#else
554 .class = I2C_CLASS_TV_ANALOG, 550 .class = I2C_CLASS_TV_ANALOG,
555#endif 551#endif
556}; 552};