diff options
author | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2012-08-06 09:48:31 -0700 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2012-08-06 09:48:31 -0700 |
commit | c87985a3ce723995fc7b25e598238d67154108a1 (patch) | |
tree | e60def1b77c25c1d74180f62e8a5603f9826f209 /drivers/hwmon/lm85.c | |
parent | d155255a344c417acad74156654295a2964e6b81 (diff) | |
parent | 0d7614f09c1ebdbaa1599a5aba7593f147bf96ee (diff) |
Merge tty-next into 3.6-rc1
This handles the merge issue in:
arch/um/drivers/line.c
arch/um/drivers/line.h
And resolves the duplicate patches that were in both trees do to the
tty-next branch not getting merged into 3.6-rc1.
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/hwmon/lm85.c')
-rw-r--r-- | drivers/hwmon/lm85.c | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/drivers/hwmon/lm85.c b/drivers/hwmon/lm85.c index 864c7d999e0..9f2dd77e1e0 100644 --- a/drivers/hwmon/lm85.c +++ b/drivers/hwmon/lm85.c @@ -1387,7 +1387,7 @@ static int lm85_probe(struct i2c_client *client, struct lm85_data *data; int err; - data = kzalloc(sizeof(struct lm85_data), GFP_KERNEL); + data = devm_kzalloc(&client->dev, sizeof(struct lm85_data), GFP_KERNEL); if (!data) return -ENOMEM; @@ -1419,7 +1419,7 @@ static int lm85_probe(struct i2c_client *client, /* Register sysfs hooks */ err = sysfs_create_group(&client->dev.kobj, &lm85_group); if (err) - goto err_kfree; + return err; /* minctl and temp_off exist on all chips except emc6d103s */ if (data->type != emc6d103s) { @@ -1466,8 +1466,6 @@ static int lm85_probe(struct i2c_client *client, /* Error out and cleanup code */ err_remove_files: lm85_remove_files(client, data); - err_kfree: - kfree(data); return err; } @@ -1476,7 +1474,6 @@ static int lm85_remove(struct i2c_client *client) struct lm85_data *data = i2c_get_clientdata(client); hwmon_device_unregister(data->hwmon_dev); lm85_remove_files(client, data); - kfree(data); return 0; } |