mirror of
git://nv-tegra.nvidia.com/linux-nv-oot.git
synced 2025-12-22 09:11:26 +03:00
devfreq: don't set last_scale for same freq
In nvhost_pod_estimate_freq(), we have *freq = 0 in case we decide to keep same frequency In that case we set *freq as current frequency and then set last_scale timestamp This can result in keeping same frequency for long duration due to less delta from last_scale To fix this, return immediately in case *freq is zero and do not set last_scale timestamp Bug 200255163 Change-Id: Ie13bf54e2415c4016a101b9ea12a9abda83240fd Signed-off-by: Deepak Nibade <dnibade@nvidia.com> Reviewed-on: http://git-master/r/1265185 Reviewed-on: http://git-master/r/1506359 (cherry picked from linux-4.9 commit be5331c94ebe9044cb67e3f622db517bfb7e28d4) Reviewed-on: https://git-master.nvidia.com/r/1770149 Reviewed-by: Mikko Perttunen <mperttunen@nvidia.com> GVS: Gerrit_Virtual_Submit Reviewed-by: Timo Alho <talho@nvidia.com> Tested-by: Timo Alho <talho@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
This commit is contained in:
committed by
Laxman Dewangan
parent
52f91e7e3e
commit
d63c243547
@@ -669,8 +669,10 @@ static int nvhost_pod_estimate_freq(struct devfreq *df,
|
||||
msecs_to_jiffies(podgov->p_slowdown_delay));
|
||||
}
|
||||
|
||||
if (!(*freq))
|
||||
if (!(*freq)) {
|
||||
*freq = dev_stat.current_frequency;
|
||||
return 0;
|
||||
}
|
||||
|
||||
if (freqlist_up(podgov, *freq, 0) == dev_stat.current_frequency)
|
||||
return 0;
|
||||
|
||||
Reference in New Issue
Block a user