thermal_hwmon.c (4eb7c2f3a3d7cd6c50f391ac555b50c3fc5b3799) thermal_hwmon.c (d9dc06009b35dd2942561bf5c939a1c91bb5d9e4)
1// SPDX-License-Identifier: GPL-2.0
2/*
3 * thermal_hwmon.c - Generic Thermal Management hwmon support.
4 *
5 * Code based on Intel thermal_core.c. Copyrights of the original code:
6 * Copyright (C) 2008 Intel Corp
7 * Copyright (C) 2008 Zhang Rui <rui.zhang@intel.com>
8 * Copyright (C) 2008 Sujith Thomas <sujith.thomas@intel.com>

--- 222 unchanged lines hidden (view full) ---

231 /* Should never happen... */
232 dev_dbg(&tz->device, "hwmon device lookup failed!\n");
233 return;
234 }
235
236 temp = thermal_hwmon_lookup_temp(hwmon, tz);
237 if (unlikely(!temp)) {
238 /* Should never happen... */
1// SPDX-License-Identifier: GPL-2.0
2/*
3 * thermal_hwmon.c - Generic Thermal Management hwmon support.
4 *
5 * Code based on Intel thermal_core.c. Copyrights of the original code:
6 * Copyright (C) 2008 Intel Corp
7 * Copyright (C) 2008 Zhang Rui <rui.zhang@intel.com>
8 * Copyright (C) 2008 Sujith Thomas <sujith.thomas@intel.com>

--- 222 unchanged lines hidden (view full) ---

231 /* Should never happen... */
232 dev_dbg(&tz->device, "hwmon device lookup failed!\n");
233 return;
234 }
235
236 temp = thermal_hwmon_lookup_temp(hwmon, tz);
237 if (unlikely(!temp)) {
238 /* Should never happen... */
239 dev_dbg(hwmon->device, "temperature input lookup failed!\n");
239 dev_dbg(&tz->device, "temperature input lookup failed!\n");
240 return;
241 }
242
243 device_remove_file(hwmon->device, &temp->temp_input.attr);
244 if (thermal_zone_crit_temp_valid(tz))
245 device_remove_file(hwmon->device, &temp->temp_crit.attr);
246
247 mutex_lock(&thermal_hwmon_list_lock);

--- 43 unchanged lines hidden ---
240 return;
241 }
242
243 device_remove_file(hwmon->device, &temp->temp_input.attr);
244 if (thermal_zone_crit_temp_valid(tz))
245 device_remove_file(hwmon->device, &temp->temp_crit.attr);
246
247 mutex_lock(&thermal_hwmon_list_lock);

--- 43 unchanged lines hidden ---