mirror of
https://github.com/ARM-software/arm-trusted-firmware.git
synced 2025-04-17 01:54:22 +00:00
tlkd: remove system off/reset handlers
TLK does not participate in the system off/reset process and so has no use for the SYSTEM_OFF/RESET notifications. This patch removes the system off/reset handlers as a result. Change-Id: Icf1430b1400cea88000e6d54426eb604a43cbe6c Signed-off-by: Varun Wadekar <vwadekar@nvidia.com>
This commit is contained in:
parent
2139c9c8bf
commit
0600cf6300
3 changed files with 3 additions and 28 deletions
|
@ -1,5 +1,6 @@
|
|||
/*
|
||||
* Copyright (c) 2015-2018, ARM Limited and Contributors. All rights reserved.
|
||||
* Copyright (c) 2020, NVIDIA Corporation. All rights reserved.
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-3-Clause
|
||||
*/
|
||||
|
@ -26,7 +27,6 @@
|
|||
#define TLK_RESUME_FID TLK_TOS_YIELD_FID(0x100)
|
||||
#define TLK_SYSTEM_SUSPEND TLK_TOS_YIELD_FID(0xE001)
|
||||
#define TLK_SYSTEM_RESUME TLK_TOS_YIELD_FID(0xE002)
|
||||
#define TLK_SYSTEM_OFF TLK_TOS_YIELD_FID(0xE003)
|
||||
#define TLK_IRQ_FIRED TLK_TOS_YIELD_FID(0xE004)
|
||||
|
||||
/*
|
||||
|
@ -39,7 +39,6 @@
|
|||
#define TLK_VA_TRANSLATE (0x32000004 | (ULL(1) << 31))
|
||||
#define TLK_SUSPEND_DONE (0x32000005 | (ULL(1) << 31))
|
||||
#define TLK_RESUME_DONE (0x32000006 | (ULL(1) << 31))
|
||||
#define TLK_SYSTEM_OFF_DONE (0x32000007 | (ULL(1) << 31))
|
||||
#define TLK_IRQ_DONE (0x32000008 | (ULL(1) << 31))
|
||||
|
||||
/*
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
/*
|
||||
* Copyright (c) 2015-2020, ARM Limited and Contributors. All rights reserved.
|
||||
* Copyright (c) 2020, NVIDIA Corporation. All rights reserved.
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-3-Clause
|
||||
*/
|
||||
|
@ -429,7 +430,6 @@ static uintptr_t tlkd_smc_handler(uint32_t smc_fid,
|
|||
*/
|
||||
case TLK_SUSPEND_DONE:
|
||||
case TLK_RESUME_DONE:
|
||||
case TLK_SYSTEM_OFF_DONE:
|
||||
|
||||
if (ns)
|
||||
SMC_RET1(handle, SMC_UNK);
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
/*
|
||||
* Copyright (c) 2015, ARM Limited and Contributors. All rights reserved.
|
||||
* Copyright (c) 2020, NVIDIA Corporation. All rights reserved.
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-3-Clause
|
||||
*/
|
||||
|
@ -97,29 +98,6 @@ static void cpu_resume_handler(u_register_t suspend_level)
|
|||
panic();
|
||||
}
|
||||
|
||||
/*******************************************************************************
|
||||
* System is about to be reset. Inform the SP to allow any book-keeping
|
||||
******************************************************************************/
|
||||
static void system_off_handler(void)
|
||||
{
|
||||
int cpu = read_mpidr() & MPIDR_CPU_MASK;
|
||||
gp_regs_t *gp_regs;
|
||||
|
||||
/* TLK runs only on CPU0 */
|
||||
if (cpu != 0)
|
||||
return;
|
||||
|
||||
/* pass system off/reset events to TLK */
|
||||
gp_regs = get_gpregs_ctx(&tlk_ctx.cpu_ctx);
|
||||
write_ctx_reg(gp_regs, CTX_GPREG_X0, TLK_SYSTEM_OFF);
|
||||
|
||||
/*
|
||||
* Enter the SP. We do not care about the return value because we
|
||||
* must continue with the shutdown anyway.
|
||||
*/
|
||||
(void)tlkd_synchronous_sp_entry(&tlk_ctx);
|
||||
}
|
||||
|
||||
/*******************************************************************************
|
||||
* Structure populated by the Dispatcher to be given a chance to perform any
|
||||
* bookkeeping before PSCI executes a power mgmt. operation.
|
||||
|
@ -128,6 +106,4 @@ const spd_pm_ops_t tlkd_pm_ops = {
|
|||
.svc_migrate_info = cpu_migrate_info,
|
||||
.svc_suspend = cpu_suspend_handler,
|
||||
.svc_suspend_finish = cpu_resume_handler,
|
||||
.svc_system_off = system_off_handler,
|
||||
.svc_system_reset = system_off_handler
|
||||
};
|
||||
|
|
Loading…
Add table
Reference in a new issue