diff options
Diffstat (limited to 'drivers/hwmon')
-rw-r--r-- | drivers/hwmon/adm1026.c | 4 | ||||
-rw-r--r-- | drivers/hwmon/adm1031.c | 4 | ||||
-rw-r--r-- | drivers/hwmon/adm9240.c | 2 | ||||
-rw-r--r-- | drivers/hwmon/fscpos.c | 2 | ||||
-rw-r--r-- | drivers/hwmon/smsc47b397.c | 2 | ||||
-rw-r--r-- | drivers/hwmon/smsc47m1.c | 2 |
6 files changed, 8 insertions, 8 deletions
diff --git a/drivers/hwmon/adm1026.c b/drivers/hwmon/adm1026.c index 4fa17c76eea2..c8a7f47911f9 100644 --- a/drivers/hwmon/adm1026.c +++ b/drivers/hwmon/adm1026.c | |||
@@ -325,7 +325,7 @@ int adm1026_attach_adapter(struct i2c_adapter *adapter) | |||
325 | int adm1026_detach_client(struct i2c_client *client) | 325 | int adm1026_detach_client(struct i2c_client *client) |
326 | { | 326 | { |
327 | i2c_detach_client(client); | 327 | i2c_detach_client(client); |
328 | kfree(client); | 328 | kfree(i2c_get_clientdata(client)); |
329 | return 0; | 329 | return 0; |
330 | } | 330 | } |
331 | 331 | ||
@@ -1691,7 +1691,7 @@ int adm1026_detect(struct i2c_adapter *adapter, int address, | |||
1691 | 1691 | ||
1692 | /* Error out and cleanup code */ | 1692 | /* Error out and cleanup code */ |
1693 | exitfree: | 1693 | exitfree: |
1694 | kfree(new_client); | 1694 | kfree(data); |
1695 | exit: | 1695 | exit: |
1696 | return err; | 1696 | return err; |
1697 | } | 1697 | } |
diff --git a/drivers/hwmon/adm1031.c b/drivers/hwmon/adm1031.c index 9168e983ca1d..936250957270 100644 --- a/drivers/hwmon/adm1031.c +++ b/drivers/hwmon/adm1031.c | |||
@@ -834,7 +834,7 @@ static int adm1031_detect(struct i2c_adapter *adapter, int address, int kind) | |||
834 | return 0; | 834 | return 0; |
835 | 835 | ||
836 | exit_free: | 836 | exit_free: |
837 | kfree(new_client); | 837 | kfree(data); |
838 | exit: | 838 | exit: |
839 | return err; | 839 | return err; |
840 | } | 840 | } |
@@ -845,7 +845,7 @@ static int adm1031_detach_client(struct i2c_client *client) | |||
845 | if ((ret = i2c_detach_client(client)) != 0) { | 845 | if ((ret = i2c_detach_client(client)) != 0) { |
846 | return ret; | 846 | return ret; |
847 | } | 847 | } |
848 | kfree(client); | 848 | kfree(i2c_get_clientdata(client)); |
849 | return 0; | 849 | return 0; |
850 | } | 850 | } |
851 | 851 | ||
diff --git a/drivers/hwmon/adm9240.c b/drivers/hwmon/adm9240.c index 5c68e9c311aa..ce2a6eb93f6e 100644 --- a/drivers/hwmon/adm9240.c +++ b/drivers/hwmon/adm9240.c | |||
@@ -616,7 +616,7 @@ static int adm9240_detect(struct i2c_adapter *adapter, int address, int kind) | |||
616 | 616 | ||
617 | return 0; | 617 | return 0; |
618 | exit_free: | 618 | exit_free: |
619 | kfree(new_client); | 619 | kfree(data); |
620 | exit: | 620 | exit: |
621 | return err; | 621 | return err; |
622 | } | 622 | } |
diff --git a/drivers/hwmon/fscpos.c b/drivers/hwmon/fscpos.c index 270015b626ad..301ae98bd0ad 100644 --- a/drivers/hwmon/fscpos.c +++ b/drivers/hwmon/fscpos.c | |||
@@ -167,7 +167,7 @@ static ssize_t set_temp_reset(struct i2c_client *client, struct fscpos_data | |||
167 | "experience to the module author.\n"); | 167 | "experience to the module author.\n"); |
168 | 168 | ||
169 | /* Supported value: 2 (clears the status) */ | 169 | /* Supported value: 2 (clears the status) */ |
170 | fscpos_write_value(client, FSCPOS_REG_TEMP_STATE[nr], 2); | 170 | fscpos_write_value(client, FSCPOS_REG_TEMP_STATE[nr - 1], 2); |
171 | return count; | 171 | return count; |
172 | } | 172 | } |
173 | 173 | ||
diff --git a/drivers/hwmon/smsc47b397.c b/drivers/hwmon/smsc47b397.c index 251ac2659554..fdeeb3ab6f2f 100644 --- a/drivers/hwmon/smsc47b397.c +++ b/drivers/hwmon/smsc47b397.c | |||
@@ -298,7 +298,7 @@ static int smsc47b397_detect(struct i2c_adapter *adapter, int addr, int kind) | |||
298 | return 0; | 298 | return 0; |
299 | 299 | ||
300 | error_free: | 300 | error_free: |
301 | kfree(new_client); | 301 | kfree(data); |
302 | error_release: | 302 | error_release: |
303 | release_region(addr, SMSC_EXTENT); | 303 | release_region(addr, SMSC_EXTENT); |
304 | return err; | 304 | return err; |
diff --git a/drivers/hwmon/smsc47m1.c b/drivers/hwmon/smsc47m1.c index 897117a7213f..7166ad0b2fda 100644 --- a/drivers/hwmon/smsc47m1.c +++ b/drivers/hwmon/smsc47m1.c | |||
@@ -495,7 +495,7 @@ static int smsc47m1_detect(struct i2c_adapter *adapter, int address, int kind) | |||
495 | return 0; | 495 | return 0; |
496 | 496 | ||
497 | error_free: | 497 | error_free: |
498 | kfree(new_client); | 498 | kfree(data); |
499 | error_release: | 499 | error_release: |
500 | release_region(address, SMSC_EXTENT); | 500 | release_region(address, SMSC_EXTENT); |
501 | return err; | 501 | return err; |