summaryrefslogtreecommitdiffstats
path: root/drivers/acpi/fan.h
diff options
context:
space:
mode:
authorSrinivas Pandruvada <srinivas.pandruvada@linux.intel.com>2022-02-11 08:09:31 -0800
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>2022-02-25 20:49:30 +0100
commitf1197343f07749035d74c08cf8b546c4f95614ab (patch)
tree684cbee49af5ef5eb698083eca2ec94efe7aeae2 /drivers/acpi/fan.h
parentbea2d9868ef553e376480de3cd84a7a06fb03e41 (diff)
downloadlinux-f1197343f07749035d74c08cf8b546c4f95614ab.tar.bz2
ACPI: fan: Add additional attributes for fine grain control
Add additional attributes, which helps in implementing algorithm in the user space to optimize fan control. These attributes are presented in the same directory as the existing performance state attributes. Additional attributes: 1. Support of fine grain control Publish support of presence of fine grain control so that fan speed can be tuned correctly. This attribute is called "fine_grain_control". 2. fan speed Publish the actual fan rpm in sysfs. Knowing fan rpm is helpful to reduce noise level and use passive control instead. Also fan performance may not be same over time, so the same control value may not be enough to run the fan at a speed. So a feedback value of speed is helpful. This sysfs attribute is called "fan_speed_rpm". Signed-off-by: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'drivers/acpi/fan.h')
-rw-r--r--drivers/acpi/fan.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/acpi/fan.h b/drivers/acpi/fan.h
index 4c01be2e3b77..44728529a5b6 100644
--- a/drivers/acpi/fan.h
+++ b/drivers/acpi/fan.h
@@ -48,8 +48,11 @@ struct acpi_fan {
struct acpi_fan_fps *fps;
int fps_count;
struct thermal_cooling_device *cdev;
+ struct device_attribute fst_speed;
+ struct device_attribute fine_grain_control;
};
+int acpi_fan_get_fst(struct acpi_device *device, struct acpi_fan_fst *fst);
int acpi_fan_create_attributes(struct acpi_device *device);
void acpi_fan_delete_attributes(struct acpi_device *device);
#endif