3.18: lockdep problems in cpufreq
Viresh Kumar
viresh.kumar at linaro.org
Mon Dec 15 19:37:28 PST 2014
On 15 December 2014 at 20:24, Yadwinder Singh Brar
<yadi.brar at samsung.com> wrote:
>> Unfortunately, you do need some kind of synchronisation here. If it's
>> not important when cpufreq_register_notifier() gets called, maybe this
>> can work:
>>
>> bool register;
>>
>> mutex_lock(&cooling_cpufreq_lock);
>> register = cpufreq_dev_count++ == 0;
>> list_add(&cpufreq_dev->node, &cpufreq_dev_list);
>> mutex_unlock(&cooling_cpufreq_lock);
>>
>> if (register)
>
> register may be 0 in scenario you stated above in second point.
> So this approach will not work.
I didn't understood what you meant here. register will be zero only
for one of the threads.
More information about the linux-arm-kernel
mailing list