aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/cpufreq/tegra-cpufreq.c
diff options
context:
space:
mode:
authorStephen Warren <swarren@nvidia.com>2013-11-20 16:06:22 -0500
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>2013-11-20 17:28:32 -0500
commit2239aa3d15056e4be807eaa8d778b247156ce552 (patch)
tree43a48d63d81f8232e08c3257b0a6aba4b12b7fd9 /drivers/cpufreq/tegra-cpufreq.c
parentaae467c79b14db0d286764ed9ddbaefe3715ebd2 (diff)
cpufreq: tegra: don't error target() when suspended
d4019f0a92ab "cpufreq: move freq change notifications to cpufreq core" added code to the cpufreq core to print an error if a cpufreq driver's .target() function returned an error. This exposed the fact that Tegra's cpufreq driver returns an error when it is ignoring requests due to the system being suspended. Modify Tegra's .target() function not to return an error in this case; this prevents the error prints. The argument is that since the suspend hook can't and doesn't inform the cpufreq core when its requests will be ignored, there's no way for the cpufreq core to squelch them, so it's not an error for the requests to keep coming. This change make the Tegra driver consistent with how the Exynos handles the same situation. Note that s5pv210-cpufreq.c probably suffers from this same issue though. Fixes: d4019f0a92ab (cpufreq: move freq change notifications to cpufreq core) Signed-off-by: Stephen Warren <swarren@nvidia.com> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Diffstat (limited to 'drivers/cpufreq/tegra-cpufreq.c')
-rw-r--r--drivers/cpufreq/tegra-cpufreq.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/cpufreq/tegra-cpufreq.c b/drivers/cpufreq/tegra-cpufreq.c
index f42df7ec03c5..b7309c37033d 100644
--- a/drivers/cpufreq/tegra-cpufreq.c
+++ b/drivers/cpufreq/tegra-cpufreq.c
@@ -142,10 +142,8 @@ static int tegra_target(struct cpufreq_policy *policy, unsigned int index)
142 142
143 mutex_lock(&tegra_cpu_lock); 143 mutex_lock(&tegra_cpu_lock);
144 144
145 if (is_suspended) { 145 if (is_suspended)
146 ret = -EBUSY;
147 goto out; 146 goto out;
148 }
149 147
150 freq = freq_table[index].frequency; 148 freq = freq_table[index].frequency;
151 149