1/* SPDX-License-Identifier: BSD-2-Clause */
2/*
3 * Copyright  2022  Beijing ESWIN Computing Technology Co., Ltd.
4 */
5
6#include <tee_syscall_numbers.h>
7#include <asm.S>
8
9        .section .text
10
11        .macro UTEE_SYSCALL name, scn, num_args
12	FUNC \name , :
13
14	.if \num_args > TEE_SVC_MAX_ARGS || \num_args > 8
15	.error "Too many arguments for syscall"
16	.endif
17	li	t0, \scn
18	li	t1, \num_args
19	ecall
20	ret
21	END_FUNC \name
22	.endm
23
24	FUNC _utee_panic, :
25	j	__utee_panic
26	END_FUNC _utee_panic
27
28#include <utee_syscalls_asm.S>
29