@@ -2009,7 +2009,7 @@ EXPORT_SYMBOL_GPL(cpufreq_driver_target);
static int __cpufreq_governor(struct cpufreq_policy *policy,
unsigned int event)
{
- int ret, state;
+ int ret, state, busy;
/* Only must be defined when default governor is known to have latency
restrictions, like e.g. conservative or ondemand.
@@ -2046,9 +2046,12 @@ static int __cpufreq_governor(struct cpufreq_policy *policy,
mutex_lock(&cpufreq_governor_lock);
state = get_governor_state(policy);
+ pr_debug("state=%u\n", state);
/* Check if operation is permitted or not */
- if (is_governor_busy(policy)
+ busy = is_governor_busy(policy);
+ pr_debug("busy=%d\n", busy);
+ if (busy
|| (state == CPUFREQ_GOV_START && event != CPUFREQ_GOV_LIMITS && event != CPUFREQ_GOV_STOP)
|| (state == CPUFREQ_GOV_STOP && event != CPUFREQ_GOV_START && event != CPUFREQ_GOV_POLICY_EXIT)
|| (state == CPUFREQ_GOV_POLICY_INIT && event != CPUFREQ_GOV_START && event != CPUFREQ_GOV_POLICY_EXIT)