summaryrefslogtreecommitdiff
path: root/arch/arm/mach-tegra/board-macallan-power.c
diff options
context:
space:
mode:
authorSivaram Nair <sivaramn@nvidia.com>2013-05-29 13:21:29 +0300
committerRiham Haidar <rhaidar@nvidia.com>2013-05-31 14:50:03 -0700
commit3dc65b43185f38e1f9768fbf85c9bf71926eb585 (patch)
treeacb7bf38442c7d444f351054c7d0a6235c51e7da /arch/arm/mach-tegra/board-macallan-power.c
parentcee8af6f8bb55992ed533b77fee52530306230d5 (diff)
ARM: tegra: dynamically init sys EDP cap
If the device is not powered by a battery, use virtualy unlimited battery cap. Change-Id: I1f6bf578af2309d1070034e57ca9b6b6e9575568 Signed-off-by: Sivaram Nair <sivaramn@nvidia.com> Reviewed-on: http://git-master/r/233652 Reviewed-by: Riham Haidar <rhaidar@nvidia.com> Tested-by: Riham Haidar <rhaidar@nvidia.com>
Diffstat (limited to 'arch/arm/mach-tegra/board-macallan-power.c')
-rw-r--r--arch/arm/mach-tegra/board-macallan-power.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/arch/arm/mach-tegra/board-macallan-power.c b/arch/arm/mach-tegra/board-macallan-power.c
index e5a42212d382..e712a9f87fdf 100644
--- a/arch/arm/mach-tegra/board-macallan-power.c
+++ b/arch/arm/mach-tegra/board-macallan-power.c
@@ -848,6 +848,9 @@ void __init macallan_sysedp_init(void)
if (!IS_ENABLED(CONFIG_EDP_FRAMEWORK))
return;
+ if (get_power_supply_type() != POWER_SUPPLY_TYPE_BATTERY)
+ macallan_sysedp_manager.max = INT_MAX;
+
r = edp_register_manager(&macallan_sysedp_manager);
WARN_ON(r);
if (r)