Skip to content
Browse files

kernel: power: prevent DVFS_LOCK_ID_USER lock for min and max frequen…

…cy levels
  • Loading branch information...
1 parent 0a809f5 commit 674ed33529f99a0b3a21646c758e3c9cd3405dc5 @gokhanmoral committed Jun 6, 2012
Showing with 11 additions and 11 deletions.
  1. +11 −11 kernel/power/main.c
View
22 kernel/power/main.c
@@ -453,7 +453,7 @@ static ssize_t cpufreq_max_limit_store(struct kobject *kobj,
if (val == -1) { /* Unlock request */
if (cpufreq_max_limit_val != -1) {
- exynos_cpufreq_upper_limit_free(DVFS_LOCK_ID_USER);
+// exynos_cpufreq_upper_limit_free(DVFS_LOCK_ID_USER);
cpufreq_max_limit_val = -1;
} else /* Already unlocked */
printk(KERN_ERR "%s: Unlock request is ignored\n",
@@ -464,12 +464,12 @@ static ssize_t cpufreq_max_limit_store(struct kobject *kobj,
if (get_cpufreq_level((unsigned int)val, &cpufreq_level)
== VALID_LEVEL) {
- if (cpufreq_max_limit_val != -1)
+// if (cpufreq_max_limit_val != -1)
/* Unlock the previous lock */
- exynos_cpufreq_upper_limit_free(
- DVFS_LOCK_ID_USER);
- lock_ret = exynos_cpufreq_upper_limit(
- DVFS_LOCK_ID_USER, cpufreq_level);
+// exynos_cpufreq_upper_limit_free(
+// DVFS_LOCK_ID_USER);
+// lock_ret = exynos_cpufreq_upper_limit(
+// DVFS_LOCK_ID_USER, cpufreq_level);
/* ret of exynos_cpufreq_upper_limit is meaningless.
0 is fail? success? */
cpufreq_max_limit_val = val;
@@ -510,19 +510,19 @@ static ssize_t cpufreq_min_limit_store(struct kobject *kobj,
if (val == -1) { /* Unlock request */
if (cpufreq_min_limit_val != -1) {
- exynos_cpufreq_lock_free(DVFS_LOCK_ID_USER);
+// exynos_cpufreq_lock_free(DVFS_LOCK_ID_USER);
cpufreq_min_limit_val = -1;
} else /* Already unlocked */
printk(KERN_ERR "%s: Unlock request is ignored\n",
__func__);
} else { /* Lock request */
if (get_cpufreq_level((unsigned int)val, &cpufreq_level)
== VALID_LEVEL) {
- if (cpufreq_min_limit_val != -1)
+// if (cpufreq_min_limit_val != -1)
/* Unlock the previous lock */
- exynos_cpufreq_lock_free(DVFS_LOCK_ID_USER);
- lock_ret = exynos_cpufreq_lock(
- DVFS_LOCK_ID_USER, cpufreq_level);
+// exynos_cpufreq_lock_free(DVFS_LOCK_ID_USER);
+// lock_ret = exynos_cpufreq_lock(
+// DVFS_LOCK_ID_USER, cpufreq_level);
/* ret of exynos_cpufreq_lock is meaningless.
0 is fail? success? */
cpufreq_min_limit_val = val;

0 comments on commit 674ed33

Please sign in to comment.
Something went wrong with that request. Please try again.