aboutsummaryrefslogtreecommitdiff
path: root/components/messaging/ffa/libsp/include/ffa_internal_api.h
blob: bfd4415f2789b8178fdc41cb60ba829832d64939 (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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
/* SPDX-License-Identifier: BSD-3-Clause */
/*
 * Copyright (c) 2020, Arm Limited and Contributors. All rights reserved.
 */

#ifndef LIBSP_INCLUDE_FFA_INTERNAL_API_H_
#define LIBSP_INCLUDE_FFA_INTERNAL_API_H_

/**
 * @file  ffa_internal_api.h
 * @brief The file contains the definition of the bottom layer of the SEL-0 FF-A
 *        implementation which SVC caller function.
 */

#include <stdint.h>

#ifdef ARM32
struct ffa_params {
	uint32_t a0;	/**< Function ID */
	uint32_t a1;	/**< Parameter */
	uint32_t a2;	/**< Parameter */
	uint32_t a3;	/**< Parameter */
	uint32_t a4;	/**< Parameter */
	uint32_t a5;	/**< Parameter */
	uint32_t a6;	/**< Parameter */
	uint32_t a7;	/**< Parameter */
};
#endif /* ARM32 */

#ifdef ARM64
struct ffa_params {
	uint64_t a0;	/**< Function ID */
	uint64_t a1;	/**< Parameter */
	uint64_t a2;	/**< Parameter */
	uint64_t a3;	/**< Parameter */
	uint64_t a4;	/**< Parameter */
	uint64_t a5;	/**< Parameter */
	uint64_t a6;	/**< Parameter */
	uint64_t a7;	/**< Parameter */
};
#endif /* ARM64 */

/**
 * @brief      SVC conduit caller function
 * @param[in]  a0, a1, a2, a3, a4, a5, a6, a7 Register values of the request
 * @param[out] result                         Register values of the response
 */
#ifdef ARM64
void ffa_svc(uint64_t a0, uint64_t a1, uint64_t a2, uint64_t a3, uint64_t a4,
	     uint64_t a5, uint64_t a6, uint64_t a7, struct ffa_params *result);
#endif /* ARM64 */

#endif /* LIBSP_INCLUDE_FFA_INTERNAL_API_H_ */