cpufreq: Mark ARM drivers with CPUFREQ_NEED_INITIAL_FREQ_CHECK flag
Sometimes boot loaders set CPU frequency to a value outside of frequency table present with cpufreq core. In such cases CPU might be unstable if it has to run on that frequency for long duration of time and so its better to set it to a frequency which is specified in frequency table. On some systems we can't really say what frequency we're running at the moment and so for these we shouldn't check if we are running at a frequency present in frequency table. And so we really can't force this for all the cpufreq drivers. Hence we are created another flag here: CPUFREQ_NEED_INITIAL_FREQ_CHECK that will be marked by platforms which want to go for this check at boot time. Initially this is done for all ARM platforms but others may follow if required. Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
This commit is contained in:

committed by
Rafael J. Wysocki

parent
20b7cbe298
commit
ae6b427132
@@ -252,6 +252,15 @@ struct cpufreq_driver {
|
||||
*/
|
||||
#define CPUFREQ_ASYNC_NOTIFICATION (1 << 4)
|
||||
|
||||
/*
|
||||
* Set by drivers which want cpufreq core to check if CPU is running at a
|
||||
* frequency present in freq-table exposed by the driver. For these drivers if
|
||||
* CPU is found running at an out of table freq, we will try to set it to a freq
|
||||
* from the table. And if that fails, we will stop further boot process by
|
||||
* issuing a BUG_ON().
|
||||
*/
|
||||
#define CPUFREQ_NEED_INITIAL_FREQ_CHECK (1 << 5)
|
||||
|
||||
int cpufreq_register_driver(struct cpufreq_driver *driver_data);
|
||||
int cpufreq_unregister_driver(struct cpufreq_driver *driver_data);
|
||||
|
||||
|
Reference in New Issue
Block a user