diff options
author | Jean Delvare <khali@linux-fr.org> | 2010-08-11 12:20:59 -0400 |
---|---|---|
committer | Jean Delvare <khali@linux-fr.org> | 2010-08-11 12:20:59 -0400 |
commit | d6703281ff20df6c2c0ea7c39a0cc2fa8be3e680 (patch) | |
tree | 493b9bb59d01bd113a0fa9df470d5093e3a07bc7 /drivers | |
parent | fe61e07e9ebc890c70d97a1f72ddaad4bee2d848 (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')
-rw-r--r-- | drivers/i2c/i2c-core.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/i2c/i2c-core.c b/drivers/i2c/i2c-core.c index e09e143379b1..bb02f8e21a3b 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) | |||
789 | 789 | ||
790 | static int i2c_register_adapter(struct i2c_adapter *adap) | 790 | static int i2c_register_adapter(struct i2c_adapter *adap) |
791 | { | 791 | { |
792 | int res = 0, dummy; | 792 | int res = 0; |
793 | 793 | ||
794 | /* Can't register until after driver model init */ | 794 | /* Can't register until after driver model init */ |
795 | if (unlikely(WARN_ON(!i2c_bus_type.p))) { | 795 | if (unlikely(WARN_ON(!i2c_bus_type.p))) { |
@@ -830,8 +830,7 @@ static int i2c_register_adapter(struct i2c_adapter *adap) | |||
830 | 830 | ||
831 | /* Notify drivers */ | 831 | /* Notify drivers */ |
832 | mutex_lock(&core_lock); | 832 | mutex_lock(&core_lock); |
833 | dummy = bus_for_each_drv(&i2c_bus_type, NULL, adap, | 833 | bus_for_each_drv(&i2c_bus_type, NULL, adap, __process_new_adapter); |
834 | __process_new_adapter); | ||
835 | mutex_unlock(&core_lock); | 834 | mutex_unlock(&core_lock); |
836 | 835 | ||
837 | return 0; | 836 | return 0; |