aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/hwmon/vt1211.c
diff options
context:
space:
mode:
authorTony Jones <tonyj@suse.de>2007-08-20 16:46:20 -0400
committerMark M. Hoffman <mhoffman@lightlink.com>2007-10-09 22:56:30 -0400
commit1beeffe43311f64df8dd0ab08ff6b1858c58363f (patch)
tree039324186049a69f3c791165e90404aef497f3cc /drivers/hwmon/vt1211.c
parent59a35bafb223bbb0553ba1a3bb9280bda668a8d8 (diff)
hwmon: Convert from class_device to device
Convert from class_device to device for hwmon_device_register/unregister Signed-off-by: Tony Jones <tonyj@suse.de> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> Signed-off-by: Kay Sievers <kay.sievers@vrfy.org> Signed-off-by: Mark M. Hoffman <mhoffman@lightlink.com>
Diffstat (limited to 'drivers/hwmon/vt1211.c')
-rw-r--r--drivers/hwmon/vt1211.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/hwmon/vt1211.c b/drivers/hwmon/vt1211.c
index 9f3e332c5b7f..e69416465e6d 100644
--- a/drivers/hwmon/vt1211.c
+++ b/drivers/hwmon/vt1211.c
@@ -108,7 +108,7 @@ static const u8 bitalarmfan[] = {6, 7};
108struct vt1211_data { 108struct vt1211_data {
109 unsigned short addr; 109 unsigned short addr;
110 const char *name; 110 const char *name;
111 struct class_device *class_dev; 111 struct device *hwmon_dev;
112 112
113 struct mutex update_lock; 113 struct mutex update_lock;
114 char valid; /* !=0 if following fields are valid */ 114 char valid; /* !=0 if following fields are valid */
@@ -1191,9 +1191,9 @@ static int __devinit vt1211_probe(struct platform_device *pdev)
1191 } 1191 }
1192 1192
1193 /* Register device */ 1193 /* Register device */
1194 data->class_dev = hwmon_device_register(dev); 1194 data->hwmon_dev = hwmon_device_register(dev);
1195 if (IS_ERR(data->class_dev)) { 1195 if (IS_ERR(data->hwmon_dev)) {
1196 err = PTR_ERR(data->class_dev); 1196 err = PTR_ERR(data->hwmon_dev);
1197 dev_err(dev, "Class registration failed (%d)\n", err); 1197 dev_err(dev, "Class registration failed (%d)\n", err);
1198 goto EXIT_DEV_REMOVE_SILENT; 1198 goto EXIT_DEV_REMOVE_SILENT;
1199 } 1199 }
@@ -1217,7 +1217,7 @@ static int __devexit vt1211_remove(struct platform_device *pdev)
1217 struct vt1211_data *data = platform_get_drvdata(pdev); 1217 struct vt1211_data *data = platform_get_drvdata(pdev);
1218 struct resource *res; 1218 struct resource *res;
1219 1219
1220 hwmon_device_unregister(data->class_dev); 1220 hwmon_device_unregister(data->hwmon_dev);
1221 vt1211_remove_sysfs(pdev); 1221 vt1211_remove_sysfs(pdev);
1222 platform_set_drvdata(pdev, NULL); 1222 platform_set_drvdata(pdev, NULL);
1223 kfree(data); 1223 kfree(data);