On Tuesday, November 25, 2014 08:56:00 PM Viresh Kumar wrote:
On 25 November 2014 at 07:14, Eduardo Valentin edubezval@gmail.com wrote:
You are right! I got confused because even with your patch, the sequencing is not working. Looking to that behavior I, somehow, thought the _init function in cpufreq-dt was about init() calls. But in fact, it is driver initialization callback.
:)
However, by the time of ->init() the cpufreq_driver is not really ready.
I agree.
Or at least, the cpufreq layer is not ready. A call to
cpufreq_frequency_get_table()
for instance, it is not working.
I know the story you pasted here :)
The cpufreq-dt would need to add the of based cpufreq cooling only when cpufreq layer is ready. Any other better cpufreq driver callback to add the cpu cooling?
There is nothing as of now atleast.
We could sort this out by polling in thermal layer for the cpufreq table until it gets ready, but I believe that would be a dirty hack.
Yeah. Probably we can add a notifier for cpufreq-driver addition/removal. That's the best we can do I believe.
Can we please avoid adding any new notifiers?
We can add a new cpufreq driver callback to be invoked by the core when everything has been set up for this purpose.