aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/hwmon/adm1029.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/hwmon/adm1029.c')
-rw-r--r--drivers/hwmon/adm1029.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/hwmon/adm1029.c b/drivers/hwmon/adm1029.c
index 73ce31b31511..0bc897dffa27 100644
--- a/drivers/hwmon/adm1029.c
+++ b/drivers/hwmon/adm1029.c
@@ -141,7 +141,7 @@ static struct i2c_driver adm1029_driver = {
141 141
142struct adm1029_data { 142struct adm1029_data {
143 struct i2c_client client; 143 struct i2c_client client;
144 struct class_device *class_dev; 144 struct device *hwmon_dev;
145 struct mutex update_lock; 145 struct mutex update_lock;
146 char valid; /* zero until following fields are valid */ 146 char valid; /* zero until following fields are valid */
147 unsigned long last_updated; /* in jiffies */ 147 unsigned long last_updated; /* in jiffies */
@@ -391,9 +391,9 @@ static int adm1029_detect(struct i2c_adapter *adapter, int address, int kind)
391 if ((err = sysfs_create_group(&client->dev.kobj, &adm1029_group))) 391 if ((err = sysfs_create_group(&client->dev.kobj, &adm1029_group)))
392 goto exit_detach; 392 goto exit_detach;
393 393
394 data->class_dev = hwmon_device_register(&client->dev); 394 data->hwmon_dev = hwmon_device_register(&client->dev);
395 if (IS_ERR(data->class_dev)) { 395 if (IS_ERR(data->hwmon_dev)) {
396 err = PTR_ERR(data->class_dev); 396 err = PTR_ERR(data->hwmon_dev);
397 goto exit_remove_files; 397 goto exit_remove_files;
398 } 398 }
399 399
@@ -431,7 +431,7 @@ static int adm1029_detach_client(struct i2c_client *client)
431 struct adm1029_data *data = i2c_get_clientdata(client); 431 struct adm1029_data *data = i2c_get_clientdata(client);
432 int err; 432 int err;
433 433
434 hwmon_device_unregister(data->class_dev); 434 hwmon_device_unregister(data->hwmon_dev);
435 sysfs_remove_group(&client->dev.kobj, &adm1029_group); 435 sysfs_remove_group(&client->dev.kobj, &adm1029_group);
436 436
437 if ((err = i2c_detach_client(client))) 437 if ((err = i2c_detach_client(client)))