From 51ff1eda6f788fc76666d275a87a7c7aff32baa8 Mon Sep 17 00:00:00 2001 From: Rajeshwari Shinde Date: Tue, 12 Feb 2013 20:40:01 +0000 Subject: EXYNOS5: Add function to setup set ps hold This patch adds a function to set ps_hold data driving value high. This enables the machine to stay powered on even after the initial power-on condition goes away(e.g. power button). Acked-by: Simon Glass Signed-off-by: Rajeshwari Shinde Signed-off-by: Minkyu Kang --- arch/arm/cpu/armv7/exynos/power.c | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'arch/arm/cpu/armv7') diff --git a/arch/arm/cpu/armv7/exynos/power.c b/arch/arm/cpu/armv7/exynos/power.c index d4bce6d4dd..400c8bcfc5 100644 --- a/arch/arm/cpu/armv7/exynos/power.c +++ b/arch/arm/cpu/armv7/exynos/power.c @@ -95,3 +95,19 @@ void set_dp_phy_ctrl(unsigned int enable) if (cpu_is_exynos5()) exynos5_dp_phy_control(enable); } + +static void exynos5_set_ps_hold_ctrl(void) +{ + struct exynos5_power *power = + (struct exynos5_power *)samsung_get_base_power(); + + /* Set PS-Hold high */ + setbits_le32(&power->ps_hold_control, + EXYNOS_PS_HOLD_CONTROL_DATA_HIGH); +} + +void set_ps_hold_ctrl(void) +{ + if (cpu_is_exynos5()) + exynos5_set_ps_hold_ctrl(); +} -- cgit From a006076b15c32e2f9c2c133697b5c662f7d1294e Mon Sep 17 00:00:00 2001 From: Rajeshwari Shinde Date: Thu, 14 Feb 2013 19:46:11 +0000 Subject: EXYNOS5: Add function to enable XXTI clock source This patch adds funtion to enable XXTI clock source required by MAX98095 codec. Signed-off-by: Rajeshwari Shinde Signed-off-by: Minkyu Kang --- arch/arm/cpu/armv7/exynos/power.c | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) (limited to 'arch/arm/cpu/armv7') diff --git a/arch/arm/cpu/armv7/exynos/power.c b/arch/arm/cpu/armv7/exynos/power.c index 400c8bcfc5..db7249ef7f 100644 --- a/arch/arm/cpu/armv7/exynos/power.c +++ b/arch/arm/cpu/armv7/exynos/power.c @@ -111,3 +111,20 @@ void set_ps_hold_ctrl(void) if (cpu_is_exynos5()) exynos5_set_ps_hold_ctrl(); } + + +static void exynos5_set_xclkout(void) +{ + struct exynos5_power *power = + (struct exynos5_power *)samsung_get_base_power(); + + /* use xxti for xclk out */ + clrsetbits_le32(&power->pmu_debug, PMU_DEBUG_CLKOUT_SEL_MASK, + PMU_DEBUG_XXTI); +} + +void set_xclkout(void) +{ + if (cpu_is_exynos5()) + exynos5_set_xclkout(); +} -- cgit From 3a0b1dae5b9b853559b87a2332a27d1ed6a91fb8 Mon Sep 17 00:00:00 2001 From: Akshay Saraswat Date: Mon, 25 Feb 2013 01:13:06 +0000 Subject: Exynos5: TMU: Add hardware tripping This adds hardware tripping at 110 degrees celsius which must enable forced system shutdown in case TMU fails to power off. Signed-off-by: Akshay Saraswat Acked-by: Simon Glass Signed-off-by: Minkyu Kang --- arch/arm/cpu/armv7/exynos/power.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'arch/arm/cpu/armv7') diff --git a/arch/arm/cpu/armv7/exynos/power.c b/arch/arm/cpu/armv7/exynos/power.c index db7249ef7f..6375a81fd4 100644 --- a/arch/arm/cpu/armv7/exynos/power.c +++ b/arch/arm/cpu/armv7/exynos/power.c @@ -128,3 +128,15 @@ void set_xclkout(void) if (cpu_is_exynos5()) exynos5_set_xclkout(); } + +/* Enables hardware tripping to power off the system when TMU fails */ +void set_hw_thermal_trip(void) +{ + if (cpu_is_exynos5()) { + struct exynos5_power *power = + (struct exynos5_power *)samsung_get_base_power(); + + /* PS_HOLD_CONTROL register ENABLE_HW_TRIP bit*/ + setbits_le32(&power->ps_hold_control, POWER_ENABLE_HW_TRIP); + } +} -- cgit