Lines Matching refs:tctx
167 struct rk_ahash_ctx *tctx = crypto_tfm_ctx(req->base.tfm); in rk_ahash_digest() local
168 struct rk_crypto_info *dev = tctx->dev; in rk_ahash_digest()
275 struct rk_ahash_ctx *tctx = crypto_tfm_ctx(tfm); in rk_cra_hash_init() local
283 tctx->dev = algt->dev; in rk_cra_hash_init()
284 tctx->dev->addr_vir = (void *)__get_free_page(GFP_KERNEL); in rk_cra_hash_init()
285 if (!tctx->dev->addr_vir) { in rk_cra_hash_init()
286 dev_err(tctx->dev->dev, "failed to kmalloc for addr_vir\n"); in rk_cra_hash_init()
289 tctx->dev->start = rk_ahash_start; in rk_cra_hash_init()
290 tctx->dev->update = rk_ahash_crypto_rx; in rk_cra_hash_init()
291 tctx->dev->complete = rk_ahash_crypto_complete; in rk_cra_hash_init()
294 tctx->fallback_tfm = crypto_alloc_ahash(alg_name, 0, in rk_cra_hash_init()
296 if (IS_ERR(tctx->fallback_tfm)) { in rk_cra_hash_init()
297 dev_err(tctx->dev->dev, "Could not load fallback driver.\n"); in rk_cra_hash_init()
298 return PTR_ERR(tctx->fallback_tfm); in rk_cra_hash_init()
302 crypto_ahash_reqsize(tctx->fallback_tfm)); in rk_cra_hash_init()
304 return tctx->dev->enable_clk(tctx->dev); in rk_cra_hash_init()
309 struct rk_ahash_ctx *tctx = crypto_tfm_ctx(tfm); in rk_cra_hash_exit() local
311 free_page((unsigned long)tctx->dev->addr_vir); in rk_cra_hash_exit()
312 return tctx->dev->disable_clk(tctx->dev); in rk_cra_hash_exit()