diff options
-rw-r--r-- | drivers/thermal/cpu_cooling.c | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/drivers/thermal/cpu_cooling.c b/drivers/thermal/cpu_cooling.c index b8b8a1ef85ed..084ef0096cc9 100644 --- a/drivers/thermal/cpu_cooling.c +++ b/drivers/thermal/cpu_cooling.c | |||
@@ -118,8 +118,14 @@ enum cpufreq_cooling_property { | |||
118 | GET_MAXL, | 118 | GET_MAXL, |
119 | }; | 119 | }; |
120 | 120 | ||
121 | /* | 121 | /** |
122 | * this is the common function to | 122 | * get_property - fetch a property of interest for a give cpu. |
123 | * @cpu: cpu for which the property is required | ||
124 | * @input: query parameter | ||
125 | * @output: query return | ||
126 | * @property: type of query (frequency, level, max level) | ||
127 | * | ||
128 | * This is the common function to | ||
123 | * 1. get maximum cpu cooling states | 129 | * 1. get maximum cpu cooling states |
124 | * 2. translate frequency to cooling state | 130 | * 2. translate frequency to cooling state |
125 | * 3. translate cooling state to frequency | 131 | * 3. translate cooling state to frequency |
@@ -128,7 +134,9 @@ enum cpufreq_cooling_property { | |||
128 | * a) reduce duplicate code as most of the code can be shared. | 134 | * a) reduce duplicate code as most of the code can be shared. |
129 | * b) make sure the logic is consistent when translating between | 135 | * b) make sure the logic is consistent when translating between |
130 | * cooling states and frequencies. | 136 | * cooling states and frequencies. |
131 | */ | 137 | * |
138 | * Return: 0 on success, -EINVAL when invalid parameters are passed. | ||
139 | */ | ||
132 | static int get_property(unsigned int cpu, unsigned long input, | 140 | static int get_property(unsigned int cpu, unsigned long input, |
133 | unsigned int* output, enum cpufreq_cooling_property property) | 141 | unsigned int* output, enum cpufreq_cooling_property property) |
134 | { | 142 | { |