diff options
author | Jean Delvare <khali@linux-fr.org> | 2005-11-26 14:28:06 -0500 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2006-01-06 01:16:21 -0500 |
commit | 8a9947552d43b0d20d5fa23ac0ba435d526be454 (patch) | |
tree | 086844a62f549e488ebeecc196e1d4726a1d4598 /drivers/i2c/chips/ds1374.c | |
parent | ff179c8cf5caa17bf3d407edbb5872aa2eee6900 (diff) |
[PATCH] i2c: Drop i2c_driver.flags, 2 of 3
Just about every i2c chip driver sets the I2C_DF_NOTIFY flag, so we
can simply make it the default and drop the flag. If any driver really
doesn't want to be notified when i2c adapters are added, that driver
can simply omit to set .attach_adapter. This approach is also more
robust as it prevents accidental NULL pointer dereferences.
Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/i2c/chips/ds1374.c')
-rw-r--r-- | drivers/i2c/chips/ds1374.c | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/drivers/i2c/chips/ds1374.c b/drivers/i2c/chips/ds1374.c index da488b735abf..5a270d60b699 100644 --- a/drivers/i2c/chips/ds1374.c +++ b/drivers/i2c/chips/ds1374.c | |||
@@ -235,7 +235,6 @@ static struct i2c_driver ds1374_driver = { | |||
235 | .owner = THIS_MODULE, | 235 | .owner = THIS_MODULE, |
236 | .name = DS1374_DRV_NAME, | 236 | .name = DS1374_DRV_NAME, |
237 | .id = I2C_DRIVERID_DS1374, | 237 | .id = I2C_DRIVERID_DS1374, |
238 | .flags = I2C_DF_NOTIFY, | ||
239 | .attach_adapter = ds1374_attach, | 238 | .attach_adapter = ds1374_attach, |
240 | .detach_client = ds1374_detach, | 239 | .detach_client = ds1374_detach, |
241 | }; | 240 | }; |