Home
last modified time | relevance | path

Searched refs:aectx (Results 1 – 2 of 2) sorted by relevance

/optee_os/core/lib/libtomcrypt/
H A Dgcm.c19 struct crypto_authenc_ctx aectx; member
26 static struct tee_gcm_state *to_tee_gcm_state(struct crypto_authenc_ctx *aectx) in to_tee_gcm_state() argument
28 assert(aectx && aectx->ops == &aes_gcm_ops); in to_tee_gcm_state()
30 return container_of(aectx, struct tee_gcm_state, aectx); in to_tee_gcm_state()
39 ctx->aectx.ops = &aes_gcm_ops; in crypto_aes_gcm_alloc_ctx()
41 *ctx_ret = &ctx->aectx; in crypto_aes_gcm_alloc_ctx()
46 static void crypto_aes_gcm_free_ctx(struct crypto_authenc_ctx *aectx) in crypto_aes_gcm_free_ctx() argument
48 free(to_tee_gcm_state(aectx)); in crypto_aes_gcm_free_ctx()
61 static TEE_Result crypto_aes_gcm_init(struct crypto_authenc_ctx *aectx, in crypto_aes_gcm_init() argument
70 struct tee_gcm_state *gcm = to_tee_gcm_state(aectx); in crypto_aes_gcm_init()
[all …]
H A Dccm.c21 struct crypto_authenc_ctx aectx; member
34 ctx->aectx.ops = &aes_ccm_ops; in crypto_aes_ccm_alloc_ctx()
36 *ctx_ret = &ctx->aectx; in crypto_aes_ccm_alloc_ctx()
40 static struct tee_ccm_state *to_tee_ccm_state(struct crypto_authenc_ctx *aectx) in to_tee_ccm_state() argument
42 assert(aectx && aectx->ops == &aes_ccm_ops); in to_tee_ccm_state()
44 return container_of(aectx, struct tee_ccm_state, aectx); in to_tee_ccm_state()
47 static void crypto_aes_ccm_free_ctx(struct crypto_authenc_ctx *aectx) in crypto_aes_ccm_free_ctx() argument
49 free(to_tee_ccm_state(aectx)); in crypto_aes_ccm_free_ctx()
62 static TEE_Result crypto_aes_ccm_init(struct crypto_authenc_ctx *aectx, in crypto_aes_ccm_init() argument
71 struct tee_ccm_state *ccm = to_tee_ccm_state(aectx); in crypto_aes_ccm_init()
[all …]