Commit 6fb75c9
committed
thermal: uniphier: Use thermal_zone_for_each_trip() for walking trip points
It is generally inefficient to iterate over trip indices and call
thermal_zone_get_trip() every time to get the struct thermal_trip
corresponding to the given trip index, so modify the uniphier thermal
driver to use thermal_zone_for_each_trip() for walking trips.
Signed-off-by: Rafael J. Wysocki <[email protected]>
Reviewed-by: Kunihiko Hayashi <[email protected]>
Link: https://patch.msgid.link/2148114.bB369e8A3T@kreacher
[ rjw: Add missing return statement, remove unused local variable ]
Signed-off-by: Rafael J. Wysocki <[email protected]>1 parent efde8bf commit 6fb75c9
1 file changed
+25
-14
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
239 | 239 | | |
240 | 240 | | |
241 | 241 | | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
| 246 | + | |
| 247 | + | |
| 248 | + | |
| 249 | + | |
| 250 | + | |
| 251 | + | |
| 252 | + | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
242 | 262 | | |
243 | 263 | | |
| 264 | + | |
244 | 265 | | |
245 | 266 | | |
246 | 267 | | |
247 | 268 | | |
248 | | - | |
| 269 | + | |
249 | 270 | | |
250 | 271 | | |
251 | 272 | | |
| |||
293 | 314 | | |
294 | 315 | | |
295 | 316 | | |
296 | | - | |
297 | | - | |
| 317 | + | |
| 318 | + | |
298 | 319 | | |
299 | | - | |
300 | | - | |
301 | | - | |
302 | | - | |
303 | | - | |
304 | | - | |
305 | | - | |
306 | | - | |
307 | | - | |
308 | | - | |
309 | | - | |
| 320 | + | |
310 | 321 | | |
311 | 322 | | |
312 | 323 | | |
| |||
0 commit comments