aboutsummaryrefslogtreecommitdiff
path: root/plat/nvidia/tegra/soc/t186/plat_psci_handlers.c
diff options
context:
space:
mode:
authorVarun Wadekar <vwadekar@nvidia.com>2017-03-14 14:25:35 -0700
committerVarun Wadekar <vwadekar@nvidia.com>2017-03-20 09:12:20 -0700
commitc7ec0892b113b7ef90807905025521e11d4b26b3 (patch)
treee5a8adaef56bc387bdd5d0df6a4d5766d82105b3 /plat/nvidia/tegra/soc/t186/plat_psci_handlers.c
parentb47d97b39588bd7b3b455980fd51acf6d316750c (diff)
downloadtrusted-firmware-a-c7ec0892b113b7ef90807905025521e11d4b26b3.tar.gz
Tegra186: implement prepare_system_off handler
This patch issues the 'System Off' ARI to power off the entire system from the 'prepare_system_off' handler. Signed-off-by: Varun Wadekar <vwadekar@nvidia.com>
Diffstat (limited to 'plat/nvidia/tegra/soc/t186/plat_psci_handlers.c')
-rw-r--r--plat/nvidia/tegra/soc/t186/plat_psci_handlers.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/plat/nvidia/tegra/soc/t186/plat_psci_handlers.c b/plat/nvidia/tegra/soc/t186/plat_psci_handlers.c
index 35b7ee9156..42f6d89b96 100644
--- a/plat/nvidia/tegra/soc/t186/plat_psci_handlers.c
+++ b/plat/nvidia/tegra/soc/t186/plat_psci_handlers.c
@@ -33,6 +33,7 @@
#include <debug.h>
#include <mce.h>
#include <psci.h>
+#include <t18x_ari.h>
#include <tegra_private.h>
int32_t tegra_soc_validate_power_state(unsigned int power_state)
@@ -93,3 +94,8 @@ int tegra_soc_prepare_cpu_off(unsigned long mpidr)
/* Turn off CPU */
return mce_command_handler(MCE_CMD_ENTER_CSTATE, ~0, 0, 0);
}
+
+__dead2 void tegra_soc_prepare_system_off(void)
+{
+ mce_enter_ccplex_state(TEGRA_ARI_MISC_CCPLEX_SHUTDOWN_POWER_OFF);
+}