blob: 908b8d0753469fc139621d067c8d95a6f0364a8f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
|
/*
* Copyright (c) 2016-2017, Arm Limited. All rights reserved.
*
* SPDX-License-Identifier: BSD-3-Clause
*/
#include <asm_macros.S>
.globl asm_tftf_smc32
/* ---------------------------------------------------------------------------
* void asm_tftf_smc32(const smc_args *args,
* smc_ret_values *smc_ret);
* ---------------------------------------------------------------------------
*/
func asm_tftf_smc32
/* Push r9 to keep the stack pointer aligned to 64 bit. */
push {r4 - r9}
/* Store the `smc_ret` pointer in a callee saved register */
mov r8, r1
/* Load values used as arguments for the SMC. */
ldm r0, {r0 - r7}
smc #0
/*
* The returned values from the SMC are in r0-r3, put them in the
* 'smc_ret_values' return structure.
*/
stm r8, {r0 - r3}
pop {r4 - r9}
bx lr
endfunc asm_tftf_smc32
|