Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 6ddcb7e6 authored by Zhang Rui's avatar Zhang Rui
Browse files

Revert "drivers: thermal: parent virtual hwmon with thermal zone"

Commit b82715fd introduces
a 'device' subdirectory under /sys/class/hwmon/hwmonX/ directory,
for the thermal_zone hwmon devices. And this results in different
handling by libsensors.

The problem is reported and discussed in this thread
http://marc.info/?l=linux-pm&m=138229306109596&w=2



This patch reverts commit b82715fd.

Reported-by: default avatarArnaud Ebalard <arno@natisbad.org>
Signed-off-by: default avatarZhang Rui <rui.zhang@intel.com>
parent df8f1347
Loading
Loading
Loading
Loading
+1 −1
Original line number Original line Diff line number Diff line
@@ -159,7 +159,7 @@ int thermal_add_hwmon_sysfs(struct thermal_zone_device *tz)


	INIT_LIST_HEAD(&hwmon->tz_list);
	INIT_LIST_HEAD(&hwmon->tz_list);
	strlcpy(hwmon->type, tz->type, THERMAL_NAME_LENGTH);
	strlcpy(hwmon->type, tz->type, THERMAL_NAME_LENGTH);
	hwmon->device = hwmon_device_register(&tz->device);
	hwmon->device = hwmon_device_register(NULL);
	if (IS_ERR(hwmon->device)) {
	if (IS_ERR(hwmon->device)) {
		result = PTR_ERR(hwmon->device);
		result = PTR_ERR(hwmon->device);
		goto free_mem;
		goto free_mem;