• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (c) 2023 Institute of Parallel And Distributed Systems (IPADS), Shanghai Jiao Tong University (SJTU)
3  * Licensed under the Mulan PSL v2.
4  * You can use this software according to the terms and conditions of the Mulan PSL v2.
5  * You may obtain a copy of Mulan PSL v2 at:
6  *     http://license.coscl.org.cn/MulanPSL2
7  * THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND, EITHER EXPRESS OR
8  * IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT, MERCHANTABILITY OR FIT FOR A PARTICULAR
9  * PURPOSE.
10  * See the Mulan PSL v2 for more details.
11  */
12 #ifndef OH_TEE_H
13 #define OH_TEE_H
14 
15 #include <stdint.h>
16 
17 #ifndef TEE_UUID_STRUCT
18 #define TEE_UUID_STRUCT
19 
20 #define NODE_LEN 8
21 
22 typedef struct tee_uuid {
23     uint32_t timeLow;
24     uint16_t timeMid;
25     uint16_t timeHiAndVersion;
26     uint8_t clockSeqAndNode[NODE_LEN];
27 } TEE_UUID;
28 
29 #endif
30 
31 #ifndef SPAWN_EXT_STRUCT
32 #define SPAWN_EXT_STRUCT
33 
34 typedef struct spawn_ext {
35     uint64_t uuid_valid;
36     TEE_UUID uuid;
37 } spawn_uuid_t;
38 
39 typedef struct {
40     unsigned version;
41     uint64_t stack_size;
42     uint64_t heap_size;
43     unsigned int flags;
44     spawn_uuid_t uuid;
45     int32_t ptid;
46 } posix_spawnattr_t;
47 
48 typedef struct {
49     int __pad0[2];
50     void *__actions;
51     int __pad[16];
52 } posix_spawn_file_actions_t;
53 
54 #endif
55 
56 #endif /* OH_TEE_H */