1 /* SPDX-License-Identifier: GPL-2.0+ */
3 * Copyright 2016 NXP Semiconductor, Inc.
7 #include <linux/linkage.h>
8 #include <asm/system.h>
11 WEAK(_sec_firmware_entry)
13 * x0: Secure Firmware entry point
14 * x1: Exception return address Low
15 * x2: Exception return address High
18 /* Save stack pointer for EL2 */
22 /* Set exception return address hold pointer */
25 #ifdef CONFIG_ARMV8_SEC_FIRMWARE_ERET_ADDR_REVERT
30 #ifdef CONFIG_ARMV8_SEC_FIRMWARE_ERET_ADDR_REVERT
35 /* Call SEC monitor */
41 ENDPROC(_sec_firmware_entry)
43 #ifdef CONFIG_SEC_FIRMWARE_ARMV8_PSCI
44 ENTRY(_sec_firmware_support_psci_version)
51 ENDPROC(_sec_firmware_support_psci_version)
54 * Switch from AArch64 EL2 to AArch32 EL2
60 * x4: kernel entry point
61 * @param outputs for secure firmware:
63 * x1: kernel entry point
67 ENTRY(armv8_el2_to_aarch32)
74 ENDPROC(armv8_el2_to_aarch32)