18#define ERROR_ENV_LINUX 0x1
19#define ERROR_ENV_ITRUSTEE 0x2
20#define ERROR_ENV_OPTEE 0x3
21#define ERROR_ENV_LITEOS 0x4
22#define ERROR_ENV_SELITEOS 0x5
23#define ERROR_ENV_NOOS 0x6
24#define ERROR_ENV_FREERTOS 0x7
25#define ERROR_ENV_ALIOS 0x8
113#define CRYPTO_COMPAT_ERRNO(env, layer, module, err_code) \
114 ((((env) & 0xF) << 28) | (((layer) & 0xF) << 24) | (((module) & 0xF) << 20) | ((err_code) & 0xFF))
117#define UAPI_COMPAT_ERRNO(module, err_code) \
118 CRYPTO_COMPAT_ERRNO(CRYPTO_ERROR_ENV, ERROR_LAYER_UAPI, module, err_code)
120#define DISPATCH_COMPAT_ERRNO(module, err_code) \
121 CRYPTO_COMPAT_ERRNO(CRYPTO_ERROR_ENV, ERROR_LAYER_DISPATCH, module, err_code)
123#define KAPI_COMPAT_ERRNO(module, err_code) \
124 CRYPTO_COMPAT_ERRNO(CRYPTO_ERROR_ENV, ERROR_LAYER_KAPI, module, err_code)
126#define DRV_COMPAT_ERRNO(module, err_code) \
127 CRYPTO_COMPAT_ERRNO(CRYPTO_ERROR_ENV, ERROR_LAYER_DRV, module, err_code)
129#define HAL_COMPAT_ERRNO(module, err_code) \
130 CRYPTO_COMPAT_ERRNO(CRYPTO_ERROR_ENV, ERROR_LAYER_HAL, module, err_code)
@ ERROR_COUNT_OVERFLOW
Definition crypto_errno.h:78
@ ERROR_INVALID_PHYS_ADDR
Definition crypto_errno.h:99
@ ERROR_HASH_LOGIC
Definition crypto_errno.h:95
@ ERROR_CMD_DISMATCH
Definition crypto_errno.h:81
@ ERROR_PKE_WAIT_DONE_TIMEOUT
Definition crypto_errno.h:109
@ ERROR_NOT_MAC_START
Definition crypto_errno.h:58
@ ERROR_MEM_HANDLE_GET
Definition crypto_errno.h:84
@ ERROR_PKE_RSA_CRYPTO_OAEP_CHECK
Definition crypto_errno.h:65
@ ERROR_INVALID_PROCESS
Definition crypto_errno.h:91
@ ERROR_PKE_RSA_VERIFY_PSS_CHECK
Definition crypto_errno.h:67
@ ERROR_PKE_LOGIC
Definition crypto_errno.h:96
@ ERROR_UNSUPPORT
Definition crypto_errno.h:52
@ ERROR_PKE_ECDSA_VERIFY_CHECK
Definition crypto_errno.h:70
@ ERROR_PKE_RSA_GEN_KEY
Definition crypto_errno.h:68
@ ERROR_INVALID_REGISTER_VALUE
Definition crypto_errno.h:98
@ ERROR_COPY_TO_USER
Definition crypto_errno.h:83
@ ERROR_INVALID_HANDLE
Definition crypto_errno.h:59
@ ERROR_MUTEX_LOCK
Definition crypto_errno.h:75
@ ERROR_UNEXPECTED
Definition crypto_errno.h:53
@ ERROR_SYMC_CALC_TIMEOUT
Definition crypto_errno.h:106
@ ERROR_COPY_FROM_USER
Definition crypto_errno.h:82
@ ERROR_PKE_RSA_SAME_DATA
Definition crypto_errno.h:63
@ ERROR_GET_PHYS_ADDR
Definition crypto_errno.h:60
@ ERROR_NOT_SET_CONFIG
Definition crypto_errno.h:56
@ ERROR_SYMC_LEN_NOT_ALIGNED
Definition crypto_errno.h:61
@ ERROR_PROCESS_NOT_INIT
Definition crypto_errno.h:88
@ ERROR_DEV_OPEN_FAILED
Definition crypto_errno.h:77
@ ERROR_MAX_PROCESS
Definition crypto_errno.h:89
@ ERROR_MUTEX_INIT
Definition crypto_errno.h:74
@ ERROR_MEMORY_ACCESS
Definition crypto_errno.h:90
@ ERROR_INVALID_PARAM
Definition crypto_errno.h:49
@ ERROR_SYMC_ADDR_NOT_ALIGNED
Definition crypto_errno.h:62
@ ERROR_HASH_CALC_TIMEOUT
Definition crypto_errno.h:104
@ ERROR_GET_OWNER
Definition crypto_errno.h:85
@ ERROR_GET_TRNG_TIMEOUT
Definition crypto_errno.h:102
@ ERROR_PKE_RSA_VERIFY_V15_CHECK
Definition crypto_errno.h:66
@ ERROR_NOT_ATTACHED
Definition crypto_errno.h:57
@ ERROR_MEMCPY_S
Definition crypto_errno.h:72
@ ERROR_CTX_CLOSED
Definition crypto_errno.h:55
@ ERROR_PKE_ROBUST_WARNING
Definition crypto_errno.h:110
@ ERROR_HASH_CLEAR_CHN_TIMEOUT
Definition crypto_errno.h:103
@ ERROR_PKE_LOCK_TIMEOUT
Definition crypto_errno.h:108
@ ERROR_INVALID_CPU_TYPE
Definition crypto_errno.h:97
@ ERROR_MALLOC
Definition crypto_errno.h:73
@ ERROR_PKE_RSA_CRYPTO_V15_CHECK
Definition crypto_errno.h:64
@ ERROR_PARAM_IS_NULL
Definition crypto_errno.h:50
@ ERROR_SYMC_CLEAR_CHN_TIMEOUT
Definition crypto_errno.h:105
@ ERROR_CHN_BUSY
Definition crypto_errno.h:54
@ ERROR_SYMC_GET_TAG_TIMEOUT
Definition crypto_errno.h:107
@ ERROR_NOT_INIT
Definition crypto_errno.h:51
@ ERROR_MODULE_SYMC
Definition crypto_errno.h:38
@ ERROR_MODULE_KM
Definition crypto_errno.h:42
@ ERROR_MODULE_PKE
Definition crypto_errno.h:40
@ ERROR_MODULE_HASH
Definition crypto_errno.h:39
@ ERROR_MODULE_OTHER
Definition crypto_errno.h:43
@ ERROR_MODULE_TRNG
Definition crypto_errno.h:41
@ CRYPTO_FAILURE
Definition crypto_errno.h:134
@ CRYPTO_SUCCESS
Definition crypto_errno.h:133
@ ERROR_LAYER_DRV
Definition crypto_errno.h:32
@ ERROR_LAYER_UAPI
Definition crypto_errno.h:29
@ ERROR_LAYER_DISPATCH
Definition crypto_errno.h:30
@ ERROR_LAYER_KAPI
Definition crypto_errno.h:31
@ ERROR_LAYER_HAL
Definition crypto_errno.h:33