Orange Pi5 kernel

Deprecated Linux kernel 5.10.110 for OrangePi 5/5B/5+ boards

3 Commits   0 Branches   0 Tags
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  1) /* SPDX-License-Identifier: GPL-2.0 */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  2) /*
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  3)  *  thermal_hwmon.h - Generic Thermal Management hwmon support.
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  4)  *
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  5)  *  Code based on Intel thermal_core.c. Copyrights of the original code:
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  6)  *  Copyright (C) 2008 Intel Corp
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  7)  *  Copyright (C) 2008 Zhang Rui <rui.zhang@intel.com>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  8)  *  Copyright (C) 2008 Sujith Thomas <sujith.thomas@intel.com>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300  9)  *
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 10)  *  Copyright (C) 2013 Texas Instruments
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 11)  *  Copyright (C) 2013 Eduardo Valentin <eduardo.valentin@ti.com>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 12)  */
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 13) #ifndef __THERMAL_HWMON_H__
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 14) #define __THERMAL_HWMON_H__
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 15) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 16) #include <linux/thermal.h>
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 17) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 18) #ifdef CONFIG_THERMAL_HWMON
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 19) int thermal_add_hwmon_sysfs(struct thermal_zone_device *tz);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 20) int devm_thermal_add_hwmon_sysfs(struct thermal_zone_device *tz);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 21) void thermal_remove_hwmon_sysfs(struct thermal_zone_device *tz);
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 22) #else
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 23) static inline int
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 24) thermal_add_hwmon_sysfs(struct thermal_zone_device *tz)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 25) {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 26) 	return 0;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 27) }
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 28) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 29) static inline int
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 30) devm_thermal_add_hwmon_sysfs(struct thermal_zone_device *tz)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 31) {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 32) 	return 0;
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 33) }
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 34) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 35) static inline void
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 36) thermal_remove_hwmon_sysfs(struct thermal_zone_device *tz)
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 37) {
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 38) }
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 39) #endif
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 40) 
^8f3ce5b39 (kx 2023-10-28 12:00:06 +0300 41) #endif /* __THERMAL_HWMON_H__ */