From 3fe2fe1e5161bd6707e4f1f392fbd5e17513d4eb Mon Sep 17 00:00:00 2001 From: Andre Przywara Date: Tue, 17 May 2016 01:18:14 +0100 Subject: PSCI: add shutdown implementation for AXP803 Now that we have the PMIC set up and directly accessible, use its power-down register to implement PSCI's SYSTEM_OFF call. Signed-off-by: Andre Przywara --- plat/sun50iw1p1/plat_pm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/plat/sun50iw1p1/plat_pm.c b/plat/sun50iw1p1/plat_pm.c index 347cc82..ec26248 100644 --- a/plat/sun50iw1p1/plat_pm.c +++ b/plat/sun50iw1p1/plat_pm.c @@ -254,10 +254,10 @@ static int32_t sunxi_affinst_suspend_finish(uint64_t mpidr, ******************************************************************************/ static void __dead2 sunxi_system_off(void) { - ERROR("PSCI system shutdown not implemented, halting the system.\n"); + sunxi_pmic_write(0x32, sunxi_pmic_read(0x32) | 0x80); + ERROR("PSCI system shutdown: still alive ...\n"); wfi(); - ERROR("Sunxi System Off: operation not handled.\n"); panic(); } -- cgit v1.2.3