History

thermal/drivers/cpuidle_cooling: Change the registration function

Today, there is no user for the cpuidle cooling device. The targetted platform is ARM and ARM64. The cpuidle and the cpufreq cooling device are based on the device tree. As the cpuidle cooling device can have its own configuration depending on the platform and the available idle states. The DT node description will give the optional properties to set the cooling device up. Do no longer rely on the CPU node which is prone to error and will lead to a confusion in the DT because the cpufreq cooling device is also using it. Let initialize the cpuidle cooling device with the DT binding. This was tested on: - hikey960 - hikey6220 - rock960 - db845c

Daniel Lezcano committed 6 years ago

Commit dfd0bda1 parent 3b258462 files · +53 −22Browse files

Showing the changes to include/linux (1 of 2 files). Show all

Unified · Split

include/linux/cpu_cooling.h+2−10
@@ -63,18 +63,10 @@ of_cpufreq_cooling_register(struct cpufreq_policy *policy) · 62 unmodified lines
63struct cpuidle_driver;63struct cpuidle_driver;
64 64
65#ifdef CONFIG_CPU_IDLE_THERMAL65#ifdef CONFIG_CPU_IDLE_THERMAL
66int cpuidle_cooling_register(struct cpuidle_driver *drv);66void cpuidle_cooling_register(struct cpuidle_driver *drv);
67int cpuidle_of_cooling_register(struct device_node *np,
68 struct cpuidle_driver *drv);
69#else /* CONFIG_CPU_IDLE_THERMAL */67#else /* CONFIG_CPU_IDLE_THERMAL */
70static inline int cpuidle_cooling_register(struct cpuidle_driver *drv)68static inline void cpuidle_cooling_register(struct cpuidle_driver *drv)
71{69{
72 return 0;
73}
74static inline int cpuidle_of_cooling_register(struct device_node *np,
75 struct cpuidle_driver *drv)
76{
77 return 0;
78}70}
79#endif /* CONFIG_CPU_IDLE_THERMAL */71#endif /* CONFIG_CPU_IDLE_THERMAL */
80 72