summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/cpufreq/cpufreq_governor.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/cpufreq/cpufreq_governor.c b/drivers/cpufreq/cpufreq_governor.c
index 56dba71d1788..65ed859030ba 100644
--- a/drivers/cpufreq/cpufreq_governor.c
+++ b/drivers/cpufreq/cpufreq_governor.c
@@ -112,7 +112,7 @@ static ssize_t governor_store(struct kobject *kobj, struct attribute *attr,
mutex_lock(&dbs_data->mutex);
- if (gattr->store)
+ if (dbs_data->usage_count && gattr->store)
ret = gattr->store(dbs_data, buf, count);
mutex_unlock(&dbs_data->mutex);