From 1dfff6bef0d779ba8d2214c109c138aff8e73320 Mon Sep 17 00:00:00 2001 From: Tony Lindgren Date: Mon, 16 Jan 2006 15:41:05 -0800 Subject: [PATCH] ARM: OMAP: Misc I2C compile fixes Misc I2C compile fixes --- drivers/i2c/chips/isp1301_omap.c | 2 +- drivers/i2c/chips/menelaus.c | 8 ++++---- drivers/i2c/chips/tlv320aic23.c | 8 ++++---- drivers/i2c/chips/tps65010.c | 8 ++++---- drivers/media/video/omap/sensor_ov9640.c | 7 ++----- include/linux/i2c-id.h | 2 ++ 6 files changed, 17 insertions(+), 18 deletions(-) diff --git a/drivers/i2c/chips/isp1301_omap.c b/drivers/i2c/chips/isp1301_omap.c index b067858f1bf..7770171ab96 100644 --- a/drivers/i2c/chips/isp1301_omap.c +++ b/drivers/i2c/chips/isp1301_omap.c @@ -49,7 +49,7 @@ #define DRIVER_VERSION "24 August 2004" -#define DRIVER_NAME (isp1301_driver.name) +#define DRIVER_NAME (isp1301_driver.driver.name) MODULE_DESCRIPTION("ISP1301 USB OTG Transceiver Driver"); MODULE_LICENSE("GPL"); diff --git a/drivers/i2c/chips/menelaus.c b/drivers/i2c/chips/menelaus.c index 48c3e3701f2..3fc037483c0 100644 --- a/drivers/i2c/chips/menelaus.c +++ b/drivers/i2c/chips/menelaus.c @@ -450,11 +450,11 @@ static int menelaus_scan_bus(struct i2c_adapter *bus) } static struct i2c_driver menelaus_i2c_driver = { - .owner = THIS_MODULE, - .name = DRIVER_NAME, - .id = I2C_DRIVERID_EXP0, /*FIXME:accroding to i2c-ids.h */ + .driver { + .name = DRIVER_NAME, + }, + .id = I2C_DRIVERID_MISC, /*FIXME:accroding to i2c-ids.h */ .class = I2C_CLASS_HWMON, - .flags = I2C_DF_NOTIFY, .attach_adapter = menelaus_scan_bus, .detach_client = menelaus_remove, }; diff --git a/drivers/i2c/chips/tlv320aic23.c b/drivers/i2c/chips/tlv320aic23.c index 43c4bac5b53..097bf8f5a44 100644 --- a/drivers/i2c/chips/tlv320aic23.c +++ b/drivers/i2c/chips/tlv320aic23.c @@ -125,10 +125,10 @@ static int tlv320aic23_attach_adapter(struct i2c_adapter *adapter) /*-----------------------------------------------------------------------*/ static struct i2c_driver tlv320aic23_driver = { - .owner = THIS_MODULE, - .name = "OMAP+TLV320AIC23 codec", - .id = I2C_DRIVERID_EXP0, /* Experimental ID */ - .flags = I2C_DF_NOTIFY, + .driver { + .name = "OMAP+TLV320AIC23 codec", + }, + .id = I2C_DRIVERID_MISC, /* Experimental ID */ .attach_adapter = tlv320aic23_attach_adapter, .detach_client = tlv320aic23_detach_client, }; diff --git a/drivers/i2c/chips/tps65010.c b/drivers/i2c/chips/tps65010.c index f009caa9ef6..f8b13206ee7 100644 --- a/drivers/i2c/chips/tps65010.c +++ b/drivers/i2c/chips/tps65010.c @@ -44,7 +44,7 @@ /*-------------------------------------------------------------------------*/ #define DRIVER_VERSION "2 May 2005" -#define DRIVER_NAME (tps65010_driver.name) +#define DRIVER_NAME (tps65010_driver.driver.name) MODULE_DESCRIPTION("TPS6501x Power Management Driver"); MODULE_LICENSE("GPL"); @@ -641,10 +641,10 @@ static int __init tps65010_scan_bus(struct i2c_adapter *bus) } static struct i2c_driver tps65010_driver = { - .owner = THIS_MODULE, - .name = "tps65010", + .driver = { + .name = "tps65010", + }, .id = 888, /* FIXME assign "official" value */ - .flags = I2C_DF_NOTIFY, .attach_adapter = tps65010_scan_bus, .detach_client = __exit_p(tps65010_detach_client), }; diff --git a/drivers/media/video/omap/sensor_ov9640.c b/drivers/media/video/omap/sensor_ov9640.c index c7691d19356..788f41d008a 100644 --- a/drivers/media/video/omap/sensor_ov9640.c +++ b/drivers/media/video/omap/sensor_ov9640.c @@ -768,7 +768,6 @@ ov9640_i2c_attach_client(struct i2c_adapter *adap, int addr, int probe) return -EBUSY; /* our client is already attached */ client->addr = addr; - client->flags = I2C_CLIENT_ALLOW_USE; client->driver = &sensor->driver; client->adapter = adap; @@ -1109,10 +1108,8 @@ ov9640sensor_init(struct v4l2_pix_format *pix) if (ov9640_powerup()) return NULL; - driver->owner = THIS_MODULE; - strlcpy(driver->name, "OV9640 I2C driver", sizeof(driver->name)); - driver->id = I2C_DRIVERID_EXP0; - driver->flags = I2C_DF_NOTIFY; + strlcpy(driver->driver.name, "OV9640 I2C driver", sizeof(driver->driver.name)); + driver->id = I2C_DRIVERID_MISC; driver->attach_adapter = ov9640_i2c_probe_adapter; driver->detach_client = ov9640_i2c_detach_client; diff --git a/include/linux/i2c-id.h b/include/linux/i2c-id.h index 6ff2d365895..2a0ddb0e578 100644 --- a/include/linux/i2c-id.h +++ b/include/linux/i2c-id.h @@ -105,6 +105,8 @@ #define I2C_DRIVERID_INFRARED 75 /* I2C InfraRed on Video boards */ #define I2C_DRIVERID_TVP5150 76 /* TVP5150 video decoder */ +#define I2C_DRIVERID_MISC 99 /* Whatever until sorted out */ + #define I2C_DRIVERID_I2CDEV 900 #define I2C_DRIVERID_ARP 902 /* SMBus ARP Client */ #define I2C_DRIVERID_ALERT 903 /* SMBus Alert Responder Client */ -- 2.41.1