Remove owner from i2c_adapter, restore inc_use and dec_use

instead.


git-svn-id: http://lm-sensors.org/svn/lm-sensors/trunk@2772 7894878c-1315-0410-8ee3-d5d059ff63e0
This commit is contained in:
Jean Delvare committed 2004-11-25 21:51:18 +00:00
1 parent f7d00ae81d
commit a223ec0fd5
20 files changed
+321 -31

No files matched your search

+17
View File
@@ -414,6 +414,21 @@ keywest_func(struct i2c_adapter * adapter)
I2C_FUNC_SMBUS_BLOCK_DATA;
}
static void
keywest_inc(struct i2c_adapter *adapter)
{
#ifdef MODULE
MOD_INC_USE_COUNT;
#endif
}
static void
keywest_dec(struct i2c_adapter *adapter)
{
#ifdef MODULE
MOD_DEC_USE_COUNT;
#endif
}
/* For now, we only handle combined mode (smbus) */
static struct i2c_algorithm keywest_algorithm = {
@@ -524,6 +539,8 @@ create_iface(struct device_node* np)
chan->adapter.id = I2C_ALGO_SMBUS;
chan->adapter.algo = &keywest_algorithm;
chan->adapter.algo_data = NULL;
chan->adapter.inc_use = keywest_inc;
chan->adapter.dec_use = keywest_dec;
chan->adapter.client_register = NULL;
chan->adapter.client_unregister = NULL;
chan->adapter.data = chan;