summaryrefslogtreecommitdiff
path: root/arch/arm/mach-tegra/nvrm
diff options
context:
space:
mode:
authorAlex Frid <afrid@nvidia.com>2010-03-19 11:02:31 -0700
committerGary King <gking@nvidia.com>2010-03-25 17:47:55 -0800
commit16addf363aca90a17319c858305aa39b921f228a (patch)
tree848effd16b4abfd2e3776a82f185491d0178bc54 /arch/arm/mach-tegra/nvrm
parente8cd4bb850fb0a31316ccaee67842fd1e0114d39 (diff)
tegra RM: Swapped the order LC and starvation hint are applied.
Swapped the order low corner (LC) limit and starvation hint are applied. After this commit, LC is applied 1st. Thus, it is guaranteed that initial starvation boost is always on top of LC (and not "under water"). Change-Id: I6bd8f2ec9f04fb51d7098a8702e4f1cf7779f4c8 Reviewed-on: http://git-master/r/935 Reviewed-by: Gary King <gking@nvidia.com> Tested-by: Gary King <gking@nvidia.com>
Diffstat (limited to 'arch/arm/mach-tegra/nvrm')
-rw-r--r--arch/arm/mach-tegra/nvrm/core/common/nvrm_power_dfs.c13
1 files changed, 5 insertions, 8 deletions
diff --git a/arch/arm/mach-tegra/nvrm/core/common/nvrm_power_dfs.c b/arch/arm/mach-tegra/nvrm/core/common/nvrm_power_dfs.c
index 18058fb53bcb..8b2357afedd4 100644
--- a/arch/arm/mach-tegra/nvrm/core/common/nvrm_power_dfs.c
+++ b/arch/arm/mach-tegra/nvrm/core/common/nvrm_power_dfs.c
@@ -1185,24 +1185,21 @@ DfsGetTargetFrequencies(
* and clip it to the domain limits. Check low power corner hit. Set
* return value if clock update is necessary.
*/
+ *pDomainKHz = NV_MAX(pDomainSampler->BumpedAverageKHz,
+ LowCornerDomainKHz);
if (pDomainSampler->RtStarveBoostKHz >= pDomainSampler->NrtStarveBoostKHz)
{
- *pDomainKHz = pDomainSampler->BumpedAverageKHz +
- pDomainSampler->RtStarveBoostKHz;
+ *pDomainKHz += pDomainSampler->RtStarveBoostKHz;
}
else
{
- *pDomainKHz = pDomainSampler->BumpedAverageKHz +
- pDomainSampler->NrtStarveBoostKHz;
+ *pDomainKHz += pDomainSampler->NrtStarveBoostKHz;
}
+
if ((*pDomainKHz) < DomainBusyKHz)
{
(*pDomainKHz) = DomainBusyKHz;
}
- if ((*pDomainKHz) < LowCornerDomainKHz)
- {
- *pDomainKHz = LowCornerDomainKHz;
- }
if ((*pDomainKHz) > HighCornerDomainKHz)
{
*pDomainKHz = HighCornerDomainKHz;