Lines Matching full:se
22 #include "tegra-se.h"
25 struct tegra_se *se; member
270 struct tegra_se *se = ctx->se; in tegra_sha_prep_cmd() local
341 host1x_uclass_incr_syncpt_indx_f(se->syncpt_id); in tegra_sha_prep_cmd()
343 dev_dbg(se->dev, "msg len %llu msg left %llu sz %zd cfg %#x", in tegra_sha_prep_cmd()
354 struct tegra_se *se = ctx->se; in tegra_sha_do_init() local
368 rctx->digest.buf = dma_alloc_coherent(se->dev, rctx->digest.size, in tegra_sha_do_init()
373 rctx->residue.buf = dma_alloc_coherent(se->dev, rctx->blk_size, in tegra_sha_do_init()
379 rctx->intr_res.buf = dma_alloc_coherent(se->dev, rctx->intr_res.size, in tegra_sha_do_init()
387 dma_free_coherent(se->dev, rctx->residue.size, rctx->residue.buf, in tegra_sha_do_init()
390 dma_free_coherent(se->dev, rctx->digest.size, rctx->digest.buf, in tegra_sha_do_init()
400 struct tegra_se *se = ctx->se; in tegra_sha_do_update() local
402 u32 *cpuvaddr = se->cmdbuf->addr; in tegra_sha_do_update()
431 rctx->datbuf.buf = dma_alloc_coherent(se->dev, rctx->datbuf.size, in tegra_sha_do_update()
454 ret = tegra_se_host1x_submit(se, se->cmdbuf, size); in tegra_sha_do_update()
456 dma_free_coherent(se->dev, rctx->datbuf.size, in tegra_sha_do_update()
467 struct tegra_se *se = ctx->se; in tegra_sha_do_final() local
468 u32 *cpuvaddr = se->cmdbuf->addr; in tegra_sha_do_final()
472 rctx->datbuf.buf = dma_alloc_coherent(se->dev, rctx->residue.size, in tegra_sha_do_final()
489 ret = tegra_se_host1x_submit(se, se->cmdbuf, size); in tegra_sha_do_final()
498 dma_free_coherent(se->dev, rctx->datbuf.size, in tegra_sha_do_final()
501 dma_free_coherent(se->dev, crypto_ahash_blocksize(tfm), in tegra_sha_do_final()
503 dma_free_coherent(se->dev, rctx->digest.size, rctx->digest.buf, in tegra_sha_do_final()
506 dma_free_coherent(se->dev, rctx->intr_res.size, rctx->intr_res.buf, in tegra_sha_do_final()
518 struct tegra_se *se = ctx->se; in tegra_sha_do_one_req() local
546 crypto_finalize_hash_request(se->engine, req, ret); in tegra_sha_do_one_req()
560 dev_warn(ctx->se->dev, in tegra_sha_init_fallback()
591 ctx->se = se_alg->se_dev; in tegra_sha_cra_init()
597 dev_err(ctx->se->dev, "invalid algorithm\n"); in tegra_sha_cra_init()
616 tegra_key_invalidate(ctx->se, ctx->key_id, ctx->alg); in tegra_sha_cra_exit()
623 dev_dbg(ctx->se->dev, "invalid key length (%d)\n", keylen); in tegra_hmac_fallback_setkey()
640 ret = tegra_key_submit(ctx->se, key, keylen, ctx->alg, &ctx->key_id); in tegra_hmac_setkey()
657 return crypto_transfer_hash_request_to_engine(ctx->se->engine, req); in tegra_sha_init()
671 return crypto_transfer_hash_request_to_engine(ctx->se->engine, req); in tegra_sha_update()
685 return crypto_transfer_hash_request_to_engine(ctx->se->engine, req); in tegra_sha_final()
699 return crypto_transfer_hash_request_to_engine(ctx->se->engine, req); in tegra_sha_finup()
713 return crypto_transfer_hash_request_to_engine(ctx->se->engine, req); in tegra_sha_digest()
759 .cra_driver_name = "tegra-se-sha1",
784 .cra_driver_name = "tegra-se-sha224",
809 .cra_driver_name = "tegra-se-sha256",
834 .cra_driver_name = "tegra-se-sha384",
859 .cra_driver_name = "tegra-se-sha512",
884 .cra_driver_name = "tegra-se-sha3-224",
909 .cra_driver_name = "tegra-se-sha3-256",
934 .cra_driver_name = "tegra-se-sha3-384",
959 .cra_driver_name = "tegra-se-sha3-512",
986 .cra_driver_name = "tegra-se-hmac-sha224",
1013 .cra_driver_name = "tegra-se-hmac-sha256",
1040 .cra_driver_name = "tegra-se-hmac-sha384",
1067 .cra_driver_name = "tegra-se-hmac-sha512",
1114 int tegra_init_hash(struct tegra_se *se) in tegra_init_hash() argument
1119 se->manifest = tegra_hash_kac_manifest; in tegra_init_hash()
1122 tegra_hash_algs[i].se_dev = se; in tegra_init_hash()
1127 dev_err(se->dev, "failed to register %s\n", in tegra_init_hash()
1142 void tegra_deinit_hash(struct tegra_se *se) in tegra_deinit_hash() argument