aboutsummaryrefslogtreecommitdiff
path: root/drivers/i2c/i2c-core.c
diff options
context:
space:
mode:
authorJean Delvare <khali@linux-fr.org>2010-08-11 18:20:59 +0200
committerJean Delvare <khali@linux-fr.org>2010-08-11 18:20:59 +0200
commitd6703281ff20df6c2c0ea7c39a0cc2fa8be3e680 (patch)
tree493b9bb59d01bd113a0fa9df470d5093e3a07bc7 /drivers/i2c/i2c-core.c
parentfe61e07e9ebc890c70d97a1f72ddaad4bee2d848 (diff)
i2c: Drop dummy variable
Now that bus_for_each_drv() is no longer __must_check, we can drop the dummy variable that was used to store the returned value. Signed-off-by: Jean Delvare <khali@linux-fr.org> Cc: Justin P. Mattock <justinmattock@gmail.com>
Diffstat (limited to 'drivers/i2c/i2c-core.c')
-rw-r--r--drivers/i2c/i2c-core.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/i2c/i2c-core.c b/drivers/i2c/i2c-core.c
index e09e143379b..bb02f8e21a3 100644
--- a/drivers/i2c/i2c-core.c
+++ b/drivers/i2c/i2c-core.c
@@ -789,7 +789,7 @@ static int __process_new_adapter(struct device_driver *d, void *data)
static int i2c_register_adapter(struct i2c_adapter *adap)
{
- int res = 0, dummy;
+ int res = 0;
/* Can't register until after driver model init */
if (unlikely(WARN_ON(!i2c_bus_type.p))) {
@@ -830,8 +830,7 @@ static int i2c_register_adapter(struct i2c_adapter *adap)
/* Notify drivers */
mutex_lock(&core_lock);
- dummy = bus_for_each_drv(&i2c_bus_type, NULL, adap,
- __process_new_adapter);
+ bus_for_each_drv(&i2c_bus_type, NULL, adap, __process_new_adapter);
mutex_unlock(&core_lock);
return 0;