summaryrefslogtreecommitdiff
path: root/arch/arm/mach-tegra/tegra3_thermal.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/mach-tegra/tegra3_thermal.c')
-rw-r--r--arch/arm/mach-tegra/tegra3_thermal.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/arch/arm/mach-tegra/tegra3_thermal.c b/arch/arm/mach-tegra/tegra3_thermal.c
index f36f84ccddf4..9de34a05810c 100644
--- a/arch/arm/mach-tegra/tegra3_thermal.c
+++ b/arch/arm/mach-tegra/tegra3_thermal.c
@@ -281,9 +281,9 @@ static void tegra_thermal_alert_unlocked(void *data)
#ifdef CONFIG_TEGRA_EDP_LIMITS
/* inform edp governor */
if (edp_thermal_zone_val != temp_tj) {
- long temp_edp = (dev2tj(device, temp_tj) - therm->edp_offset) / 1000;
+ long temp_edp = (temp_tj - therm->edp_offset) / 1000;
tegra_edp_update_thermal_zone(temp_edp);
- edp_thermal_zone_val = temp_edp;
+ edp_thermal_zone_val = temp_tj;
}
#endif
}
@@ -441,7 +441,6 @@ int tegra_thermal_device_register(struct tegra_thermal_device *device)
tegra_skin_device_register(device);
#endif
- register_pm_notifier(&tegra_thermal_nb);
return 0;
}
@@ -477,6 +476,8 @@ int __init tegra_thermal_init(struct tegra_thermal_data *data,
throttle_list = tlist;
throttle_list_size = tlist_size;
+ register_pm_notifier(&tegra_thermal_nb);
+
return 0;
}