Lines Matching refs:qce

31 	struct qce_device *qce = tmpl->qce;  in qce_ablkcipher_done()  local
41 error = qce_dma_terminate_all(&qce->dma); in qce_ablkcipher_done()
43 dev_dbg(qce->dev, "ablkcipher dma termination error (%d)\n", in qce_ablkcipher_done()
47 dma_unmap_sg(qce->dev, rctx->src_sg, rctx->src_nents, dir_src); in qce_ablkcipher_done()
48 dma_unmap_sg(qce->dev, rctx->dst_sg, rctx->dst_nents, dir_dst); in qce_ablkcipher_done()
52 error = qce_check_status(qce, &status); in qce_ablkcipher_done()
54 dev_dbg(qce->dev, "ablkcipher operation error (%x)\n", status); in qce_ablkcipher_done()
56 qce->async_req_done(tmpl->qce, error); in qce_ablkcipher_done()
66 struct qce_device *qce = tmpl->qce; in qce_ablkcipher_async_req_handle() local
87 dev_err(qce->dev, "Invalid numbers of src SG.\n"); in qce_ablkcipher_async_req_handle()
91 dev_err(qce->dev, "Invalid numbers of dst SG.\n"); in qce_ablkcipher_async_req_handle()
104 sg_init_one(&rctx->result_sg, qce->dma.result_buf, QCE_RESULT_BUF_SZ); in qce_ablkcipher_async_req_handle()
121 ret = dma_map_sg(qce->dev, rctx->dst_sg, rctx->dst_nents, dir_dst); in qce_ablkcipher_async_req_handle()
126 ret = dma_map_sg(qce->dev, req->src, rctx->src_nents, dir_src); in qce_ablkcipher_async_req_handle()
134 ret = qce_dma_prep_sgs(&qce->dma, rctx->src_sg, rctx->src_nents, in qce_ablkcipher_async_req_handle()
140 qce_dma_issue_pending(&qce->dma); in qce_ablkcipher_async_req_handle()
149 qce_dma_terminate_all(&qce->dma); in qce_ablkcipher_async_req_handle()
152 dma_unmap_sg(qce->dev, req->src, rctx->src_nents, dir_src); in qce_ablkcipher_async_req_handle()
154 dma_unmap_sg(qce->dev, rctx->dst_sg, rctx->dst_nents, dir_dst); in qce_ablkcipher_async_req_handle()
228 return tmpl->qce->async_req_enqueue(tmpl->qce, &req->base); in qce_ablkcipher_crypt()
347 struct qce_device *qce) in qce_ablkcipher_register_one() argument
385 tmpl->qce = qce; in qce_ablkcipher_register_one()
390 dev_err(qce->dev, "%s registration failed\n", alg->cra_name); in qce_ablkcipher_register_one()
395 dev_dbg(qce->dev, "%s is registered\n", alg->cra_name); in qce_ablkcipher_register_one()
399 static void qce_ablkcipher_unregister(struct qce_device *qce) in qce_ablkcipher_unregister() argument
410 static int qce_ablkcipher_register(struct qce_device *qce) in qce_ablkcipher_register() argument
415 ret = qce_ablkcipher_register_one(&ablkcipher_def[i], qce); in qce_ablkcipher_register()
422 qce_ablkcipher_unregister(qce); in qce_ablkcipher_register()