drm/amdgpu/gmc9: rework stolen vga memory handling
[linux-2.6-microblaze.git] / drivers / thermal / thermal_hwmon.c
index 1127883..40c69a5 100644 (file)
@@ -142,7 +142,8 @@ int thermal_add_hwmon_sysfs(struct thermal_zone_device *tz)
 
        INIT_LIST_HEAD(&hwmon->tz_list);
        strlcpy(hwmon->type, tz->type, THERMAL_NAME_LENGTH);
-       hwmon->device = hwmon_device_register_with_info(NULL, hwmon->type,
+       strreplace(hwmon->type, '-', '_');
+       hwmon->device = hwmon_device_register_with_info(&tz->device, hwmon->type,
                                                        hwmon, NULL, NULL);
        if (IS_ERR(hwmon->device)) {
                result = PTR_ERR(hwmon->device);