From 40429e13014675e82e1126c5df87c9008aee92c1 Mon Sep 17 00:00:00 2001 From: Varun Wadekar Date: Thu, 12 May 2011 14:25:01 +0530 Subject: arm: tegra: cardhu: set CPU EDP limits Change-Id: I6282bbb63c34b8cc0d503cdd6eafe575fb78ef5f Signed-off-by: Varun Wadekar Reviewed-on: http://git-master/r/31342 Reviewed-by: Varun Colbert Tested-by: Varun Colbert --- arch/arm/mach-tegra/board-cardhu-power.c | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) (limited to 'arch/arm/mach-tegra/board-cardhu-power.c') diff --git a/arch/arm/mach-tegra/board-cardhu-power.c b/arch/arm/mach-tegra/board-cardhu-power.c index f593d9fe4d11..6af7c4a85b51 100644 --- a/arch/arm/mach-tegra/board-cardhu-power.c +++ b/arch/arm/mach-tegra/board-cardhu-power.c @@ -33,6 +33,7 @@ #include #include #include +#include #include "gpio-names.h" #include "board.h" @@ -943,3 +944,29 @@ int __init cardhu_power_off_init(void) return 0; } +#ifdef CONFIG_TEGRA_EDP_LIMITS +/* + * placeholder for now. needs to be changed with characterized data. + * step size cannot be less than 4C + */ +static struct tegra_edp_limits cardhu_edp_limits[] = { +/* Temperature 1 CPU 2 CPUs 3 CPUs 4 CPUs */ + {60, {1400000, 1300000, 1300000, 1300000}}, + {70, {1400000, 1300000, 1300000, 1260000}}, + {80, {1400000, 1300000, 1300000, 1200000}}, + {90, {1400000, 1300000, 1300000, 1100000}}, +}; + +void cardhu_thermal_zones_info(struct tegra_edp_limits **z, int *sz) +{ + *z = cardhu_edp_limits; + *sz = ARRAY_SIZE(cardhu_edp_limits); +} + +int __init cardhu_edp_init(void) +{ + // FIXME: uncomment to override default EDP with above table + //tegra_init_cpu_edp_limits(cardhu_edp_limits, ARRAY_SIZE(cardhu_edp_limits)); + return 0; +} +#endif -- cgit v1.2.3