summaryrefslogtreecommitdiffstats
path: root/include/linux/thermal.h
diff options
context:
space:
mode:
authorAngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>2024-01-30 12:12:33 +0100
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>2024-02-02 19:12:58 +0100
commitb377252eeec91f347cd538011f956a4fe73794b3 (patch)
tree95e3752faa1ad22fa025a7283128cbd826bd4729 /include/linux/thermal.h
parent54d94009cb6f51d3ecd56bfc63c83e789c0b18b4 (diff)
downloadlinux-b377252eeec91f347cd538011f956a4fe73794b3.tar.gz
linux-b377252eeec91f347cd538011f956a4fe73794b3.tar.bz2
linux-b377252eeec91f347cd538011f956a4fe73794b3.zip
thermal: core: Change governor name to const char pointer
All users are already assigning a const char * to the `governor_name` member of struct thermal_zone_params and to the `name` member of struct thermal_governor. Even if users are technically wrong, it just makes more sense to change this member to be a const char pointer instead of doing the other way around. Signed-off-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'include/linux/thermal.h')
-rw-r--r--include/linux/thermal.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/linux/thermal.h b/include/linux/thermal.h
index b7a3deb372fd..65d8f92a9a0d 100644
--- a/include/linux/thermal.h
+++ b/include/linux/thermal.h
@@ -214,7 +214,7 @@ struct thermal_zone_device {
* @governor_list: node in thermal_governor_list (in thermal_core.c)
*/
struct thermal_governor {
- char name[THERMAL_NAME_LENGTH];
+ const char *name;
int (*bind_to_tz)(struct thermal_zone_device *tz);
void (*unbind_from_tz)(struct thermal_zone_device *tz);
int (*throttle)(struct thermal_zone_device *tz,
@@ -226,7 +226,7 @@ struct thermal_governor {
/* Structure to define Thermal Zone parameters */
struct thermal_zone_params {
- char governor_name[THERMAL_NAME_LENGTH];
+ const char *governor_name;
/*
* a boolean to indicate if the thermal to hwmon sysfs interface