diff options
author | MyungJoo Ham <myungjoo.ham@samsung.com> | 2011-12-09 11:42:19 +0400 |
---|---|---|
committer | MyungJoo Ham <myungjoo.ham@samsung.com> | 2012-01-20 05:12:38 +0400 |
commit | 6530b9dea1b7f33eaf79ba625e3a99f2455f3eb1 (patch) | |
tree | 70beddf04779d5941ba6ef851b30e02c7fa0c86c /drivers/devfreq/governor_performance.c | |
parent | a95e1f5dbca385908aa4087bb98470b0e0ac58d8 (diff) | |
download | linux-6530b9dea1b7f33eaf79ba625e3a99f2455f3eb1.tar.xz |
PM / devfreq: add min/max_freq limit requested by users.
The frequency requested to devfreq device driver from devfreq governors
is restricted by min_freq and max_freq input.
Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Diffstat (limited to 'drivers/devfreq/governor_performance.c')
-rw-r--r-- | drivers/devfreq/governor_performance.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/devfreq/governor_performance.c b/drivers/devfreq/governor_performance.c index c0596b291761..574a06b1b1de 100644 --- a/drivers/devfreq/governor_performance.c +++ b/drivers/devfreq/governor_performance.c @@ -18,7 +18,10 @@ static int devfreq_performance_func(struct devfreq *df, * target callback should be able to get floor value as * said in devfreq.h */ - *freq = UINT_MAX; + if (!df->max_freq) + *freq = UINT_MAX; + else + *freq = df->max_freq; return 0; } |