cpufreq: cpu-boost: Don't register for cpufreq notifiers too early
The cpufreq notifiers should be registered only after all the data structures used in the notifier callbacks have been initialized. So, move the cpufreq notifier registration to a later point in the init function. Change-Id: I043ab5bc0ebb98164c40549fe151a8d801c8c186 Signed-off-by: Saravana Kannan <skannan@codeaurora.org>
This commit is contained in:
parent
2f97ec6d6e
commit
2eb27275fc
1 changed files with 2 additions and 3 deletions
|
@ -338,8 +338,6 @@ static int cpu_boost_init(void)
|
|||
int cpu, ret;
|
||||
struct cpu_sync *s;
|
||||
|
||||
cpufreq_register_notifier(&boost_adjust_nb, CPUFREQ_POLICY_NOTIFIER);
|
||||
|
||||
cpu_boost_wq = alloc_workqueue("cpuboost_wq", WQ_HIGHPRI, 0);
|
||||
if (!cpu_boost_wq)
|
||||
return -EFAULT;
|
||||
|
@ -357,10 +355,11 @@ static int cpu_boost_init(void)
|
|||
"boost_sync/%d", cpu);
|
||||
set_cpus_allowed(s->thread, *cpumask_of(cpu));
|
||||
}
|
||||
cpufreq_register_notifier(&boost_adjust_nb, CPUFREQ_POLICY_NOTIFIER);
|
||||
atomic_notifier_chain_register(&migration_notifier_head,
|
||||
&boost_migration_nb);
|
||||
|
||||
ret = input_register_handler(&cpuboost_input_handler);
|
||||
|
||||
return 0;
|
||||
}
|
||||
late_initcall(cpu_boost_init);
|
||||
|
|
Loading…
Add table
Reference in a new issue