Gyorgy Szing | 4909180 | 2020-11-24 00:33:09 +0100 | [diff] [blame] | 1 | /* |
Imre Kis | 2f66713 | 2021-05-12 12:35:10 +0200 | [diff] [blame] | 2 | * Copyright (c) 2020-2021, Arm Limited and Contributors. All rights reserved. |
Gyorgy Szing | 4909180 | 2020-11-24 00:33:09 +0100 | [diff] [blame] | 3 | * |
| 4 | * SPDX-License-Identifier: BSD-3-Clause |
| 5 | */ |
| 6 | |
| 7 | #include "ffa_internal_api.h" |
| 8 | #include "optee_sp_internal_api.h" |
| 9 | #include "sp_api.h" |
| 10 | |
| 11 | void __noreturn optee_sp_entry(uintptr_t a0, uintptr_t a1, uintptr_t a2, |
| 12 | uintptr_t a3) |
| 13 | { |
| 14 | (void)a1; |
| 15 | (void)a2; |
| 16 | (void)a3; |
| 17 | |
| 18 | sp_main((struct ffa_init_info *)a0); |
| 19 | } |
| 20 | |
| 21 | void optee_sp_log_puts(const char *str) |
| 22 | { |
Imre Kis | 2f66713 | 2021-05-12 12:35:10 +0200 | [diff] [blame] | 23 | struct ffa_params resp; |
| 24 | |
| 25 | ffa_svc(0xdeadbeef, (uintptr_t)str, 0, 0, 0, 0, 0, 0, &resp); |
Gyorgy Szing | 4909180 | 2020-11-24 00:33:09 +0100 | [diff] [blame] | 26 | } |
| 27 | |
| 28 | void __noreturn optee_sp_panic(void) |
| 29 | { |
| 30 | while (1) |
| 31 | ; |
| 32 | } |