• Home
  • Raw
  • Download

Lines Matching refs:u

366 		op->src.u.dma.address = src->dm_wa.dma.address;  in ccp_prepare_data()
367 op->src.u.dma.offset = 0; in ccp_prepare_data()
368 op->src.u.dma.length = (blocksize_op) ? block_size : cp_len; in ccp_prepare_data()
373 op->src.u.dma.address = sg_dma_address(src->sg_wa.sg); in ccp_prepare_data()
374 op->src.u.dma.offset = src->sg_wa.sg_used; in ccp_prepare_data()
375 op->src.u.dma.length = op_len & ~(block_size - 1); in ccp_prepare_data()
377 ccp_update_sg_workarea(&src->sg_wa, op->src.u.dma.length); in ccp_prepare_data()
387 op->dst.u.dma.address = dst->dm_wa.dma.address; in ccp_prepare_data()
388 op->dst.u.dma.offset = 0; in ccp_prepare_data()
389 op->dst.u.dma.length = op->src.u.dma.length; in ccp_prepare_data()
394 op->dst.u.dma.address = sg_dma_address(dst->sg_wa.sg); in ccp_prepare_data()
395 op->dst.u.dma.offset = dst->sg_wa.sg_used; in ccp_prepare_data()
396 op->dst.u.dma.length = op->src.u.dma.length; in ccp_prepare_data()
407 if (op->dst.u.dma.address == dst->dm_wa.dma.address) in ccp_process_data()
411 op->dst.u.dma.length); in ccp_process_data()
430 op.src.u.sb = sb; in ccp_copy_to_from_sb()
432 op.dst.u.dma.address = wa->dma.address; in ccp_copy_to_from_sb()
433 op.dst.u.dma.length = wa->length; in ccp_copy_to_from_sb()
436 op.src.u.dma.address = wa->dma.address; in ccp_copy_to_from_sb()
437 op.src.u.dma.length = wa->length; in ccp_copy_to_from_sb()
439 op.dst.u.sb = sb; in ccp_copy_to_from_sb()
442 op.u.passthru.byte_swap = byte_swap; in ccp_copy_to_from_sb()
464 struct ccp_aes_engine *aes = &cmd->u.aes; in ccp_run_aes_cmac_cmd()
503 op.u.aes.type = aes->type; in ccp_run_aes_cmac_cmd()
504 op.u.aes.mode = aes->mode; in ccp_run_aes_cmac_cmd()
505 op.u.aes.action = aes->action; in ccp_run_aes_cmac_cmd()
620 struct ccp_aes_engine *aes = &cmd->u.aes; in ccp_run_aes_gcm_cmd()
691 op.u.aes.type = aes->type; in ccp_run_aes_gcm_cmd()
742 op.u.aes.mode = CCP_AES_MODE_GHASH; in ccp_run_aes_gcm_cmd()
743 op.u.aes.action = CCP_AES_GHASHAAD; in ccp_run_aes_gcm_cmd()
759 op.u.aes.mode = CCP_AES_MODE_GCTR; in ccp_run_aes_gcm_cmd()
760 op.u.aes.action = aes->action; in ccp_run_aes_gcm_cmd()
792 op.u.aes.size = (nbytes * 8) - 1; in ccp_run_aes_gcm_cmd()
843 op.u.aes.type = aes->type; in ccp_run_aes_gcm_cmd()
844 op.u.aes.mode = CCP_AES_MODE_GHASH; in ccp_run_aes_gcm_cmd()
845 op.u.aes.action = CCP_AES_GHASHFINAL; in ccp_run_aes_gcm_cmd()
847 op.src.u.dma.address = final_wa.dma.address; in ccp_run_aes_gcm_cmd()
848 op.src.u.dma.length = AES_BLOCK_SIZE; in ccp_run_aes_gcm_cmd()
850 op.dst.u.dma.address = final_wa.dma.address; in ccp_run_aes_gcm_cmd()
851 op.dst.u.dma.length = AES_BLOCK_SIZE; in ccp_run_aes_gcm_cmd()
853 op.u.aes.size = 0; in ccp_run_aes_gcm_cmd()
903 struct ccp_aes_engine *aes = &cmd->u.aes; in ccp_run_aes_cmd()
943 op.u.aes.type = aes->type; in ccp_run_aes_cmd()
944 op.u.aes.mode = aes->mode; in ccp_run_aes_cmd()
945 op.u.aes.action = aes->action; in ccp_run_aes_cmd()
995 op.u.aes.size = AES_BLOCK_SIZE * BITS_PER_BYTE - 1; in ccp_run_aes_cmd()
998 op.u.aes.size = 0; in ccp_run_aes_cmd()
1081 struct ccp_xts_aes_engine *xts = &cmd->u.xts; in ccp_run_xts_aes_cmd()
1138 op.u.xts.type = aestype; in ccp_run_xts_aes_cmd()
1139 op.u.xts.action = xts->action; in ccp_run_xts_aes_cmd()
1140 op.u.xts.unit_size = xts->unit_size; in ccp_run_xts_aes_cmd()
1281 struct ccp_des3_engine *des3 = &cmd->u.des3; in ccp_run_des3_cmd()
1327 op.u.des3.type = des3->type; in ccp_run_des3_cmd()
1328 op.u.des3.mode = des3->mode; in ccp_run_des3_cmd()
1329 op.u.des3.action = des3->action; in ccp_run_des3_cmd()
1478 struct ccp_sha_engine *sha = &cmd->u.sha; in ccp_run_sha_cmd()
1635 op.u.sha.type = sha->type; in ccp_run_sha_cmd()
1636 op.u.sha.msg_bits = sha->msg_bits; in ccp_run_sha_cmd()
1792 hmac_cmd.u.sha.type = sha->type; in ccp_run_sha_cmd()
1793 hmac_cmd.u.sha.ctx = sha->ctx; in ccp_run_sha_cmd()
1794 hmac_cmd.u.sha.ctx_len = sha->ctx_len; in ccp_run_sha_cmd()
1795 hmac_cmd.u.sha.src = &sg; in ccp_run_sha_cmd()
1796 hmac_cmd.u.sha.src_len = block_size + digest_size; in ccp_run_sha_cmd()
1797 hmac_cmd.u.sha.opad = NULL; in ccp_run_sha_cmd()
1798 hmac_cmd.u.sha.opad_len = 0; in ccp_run_sha_cmd()
1799 hmac_cmd.u.sha.first = 1; in ccp_run_sha_cmd()
1800 hmac_cmd.u.sha.final = 1; in ccp_run_sha_cmd()
1801 hmac_cmd.u.sha.msg_bits = (block_size + digest_size) << 3; in ccp_run_sha_cmd()
1823 struct ccp_rsa_engine *rsa = &cmd->u.rsa; in ccp_run_rsa_cmd()
1893 op.exp.u.dma.address = exp.dma.address; in ccp_run_rsa_cmd()
1894 op.exp.u.dma.offset = 0; in ccp_run_rsa_cmd()
1918 op.src.u.dma.address = src.dma.address; in ccp_run_rsa_cmd()
1919 op.src.u.dma.offset = 0; in ccp_run_rsa_cmd()
1920 op.src.u.dma.length = i_len; in ccp_run_rsa_cmd()
1921 op.dst.u.dma.address = dst.dma.address; in ccp_run_rsa_cmd()
1922 op.dst.u.dma.offset = 0; in ccp_run_rsa_cmd()
1923 op.dst.u.dma.length = o_len; in ccp_run_rsa_cmd()
1925 op.u.rsa.mod_size = rsa->key_size; in ccp_run_rsa_cmd()
1926 op.u.rsa.input_len = i_len; in ccp_run_rsa_cmd()
1955 struct ccp_passthru_engine *pt = &cmd->u.passthru; in ccp_run_passthru_cmd()
2047 op.src.u.dma.address = sg_dma_address(src.sg_wa.sg); in ccp_run_passthru_cmd()
2048 op.src.u.dma.offset = 0; in ccp_run_passthru_cmd()
2049 op.src.u.dma.length = sg_dma_len(src.sg_wa.sg); in ccp_run_passthru_cmd()
2052 op.dst.u.dma.address = sg_dma_address(dst.sg_wa.sg); in ccp_run_passthru_cmd()
2053 op.dst.u.dma.offset = dst.sg_wa.sg_used; in ccp_run_passthru_cmd()
2054 op.dst.u.dma.length = op.src.u.dma.length; in ccp_run_passthru_cmd()
2088 struct ccp_passthru_nomap_engine *pt = &cmd->u.passthru_nomap; in ccp_run_passthru_nomap_cmd()
2133 op.src.u.dma.address = pt->src_dma; in ccp_run_passthru_nomap_cmd()
2134 op.src.u.dma.offset = 0; in ccp_run_passthru_nomap_cmd()
2135 op.src.u.dma.length = pt->src_len; in ccp_run_passthru_nomap_cmd()
2138 op.dst.u.dma.address = pt->dst_dma; in ccp_run_passthru_nomap_cmd()
2139 op.dst.u.dma.offset = 0; in ccp_run_passthru_nomap_cmd()
2140 op.dst.u.dma.length = pt->src_len; in ccp_run_passthru_nomap_cmd()
2151 struct ccp_ecc_engine *ecc = &cmd->u.ecc; in ccp_run_ecc_mm_cmd()
2157 if (!ecc->u.mm.operand_1 || in ccp_run_ecc_mm_cmd()
2158 (ecc->u.mm.operand_1_len > CCP_ECC_MODULUS_BYTES)) in ccp_run_ecc_mm_cmd()
2162 if (!ecc->u.mm.operand_2 || in ccp_run_ecc_mm_cmd()
2163 (ecc->u.mm.operand_2_len > CCP_ECC_MODULUS_BYTES)) in ccp_run_ecc_mm_cmd()
2166 if (!ecc->u.mm.result || in ccp_run_ecc_mm_cmd()
2167 (ecc->u.mm.result_len < CCP_ECC_MODULUS_BYTES)) in ccp_run_ecc_mm_cmd()
2196 ret = ccp_reverse_set_dm_area(&src, 0, ecc->u.mm.operand_1, 0, in ccp_run_ecc_mm_cmd()
2197 ecc->u.mm.operand_1_len); in ccp_run_ecc_mm_cmd()
2204 ret = ccp_reverse_set_dm_area(&src, 0, ecc->u.mm.operand_2, 0, in ccp_run_ecc_mm_cmd()
2205 ecc->u.mm.operand_2_len); in ccp_run_ecc_mm_cmd()
2221 op.src.u.dma.address = src.dma.address; in ccp_run_ecc_mm_cmd()
2222 op.src.u.dma.offset = 0; in ccp_run_ecc_mm_cmd()
2223 op.src.u.dma.length = src.length; in ccp_run_ecc_mm_cmd()
2224 op.dst.u.dma.address = dst.dma.address; in ccp_run_ecc_mm_cmd()
2225 op.dst.u.dma.offset = 0; in ccp_run_ecc_mm_cmd()
2226 op.dst.u.dma.length = dst.length; in ccp_run_ecc_mm_cmd()
2228 op.u.ecc.function = cmd->u.ecc.function; in ccp_run_ecc_mm_cmd()
2244 ccp_reverse_get_dm_area(&dst, 0, ecc->u.mm.result, 0, in ccp_run_ecc_mm_cmd()
2258 struct ccp_ecc_engine *ecc = &cmd->u.ecc; in ccp_run_ecc_pm_cmd()
2264 if (!ecc->u.pm.point_1.x || in ccp_run_ecc_pm_cmd()
2265 (ecc->u.pm.point_1.x_len > CCP_ECC_MODULUS_BYTES) || in ccp_run_ecc_pm_cmd()
2266 !ecc->u.pm.point_1.y || in ccp_run_ecc_pm_cmd()
2267 (ecc->u.pm.point_1.y_len > CCP_ECC_MODULUS_BYTES)) in ccp_run_ecc_pm_cmd()
2271 if (!ecc->u.pm.point_2.x || in ccp_run_ecc_pm_cmd()
2272 (ecc->u.pm.point_2.x_len > CCP_ECC_MODULUS_BYTES) || in ccp_run_ecc_pm_cmd()
2273 !ecc->u.pm.point_2.y || in ccp_run_ecc_pm_cmd()
2274 (ecc->u.pm.point_2.y_len > CCP_ECC_MODULUS_BYTES)) in ccp_run_ecc_pm_cmd()
2277 if (!ecc->u.pm.domain_a || in ccp_run_ecc_pm_cmd()
2278 (ecc->u.pm.domain_a_len > CCP_ECC_MODULUS_BYTES)) in ccp_run_ecc_pm_cmd()
2282 if (!ecc->u.pm.scalar || in ccp_run_ecc_pm_cmd()
2283 (ecc->u.pm.scalar_len > CCP_ECC_MODULUS_BYTES)) in ccp_run_ecc_pm_cmd()
2287 if (!ecc->u.pm.result.x || in ccp_run_ecc_pm_cmd()
2288 (ecc->u.pm.result.x_len < CCP_ECC_MODULUS_BYTES) || in ccp_run_ecc_pm_cmd()
2289 !ecc->u.pm.result.y || in ccp_run_ecc_pm_cmd()
2290 (ecc->u.pm.result.y_len < CCP_ECC_MODULUS_BYTES)) in ccp_run_ecc_pm_cmd()
2319 ret = ccp_reverse_set_dm_area(&src, 0, ecc->u.pm.point_1.x, 0, in ccp_run_ecc_pm_cmd()
2320 ecc->u.pm.point_1.x_len); in ccp_run_ecc_pm_cmd()
2324 ret = ccp_reverse_set_dm_area(&src, 0, ecc->u.pm.point_1.y, 0, in ccp_run_ecc_pm_cmd()
2325 ecc->u.pm.point_1.y_len); in ccp_run_ecc_pm_cmd()
2336 ret = ccp_reverse_set_dm_area(&src, 0, ecc->u.pm.point_2.x, 0, in ccp_run_ecc_pm_cmd()
2337 ecc->u.pm.point_2.x_len); in ccp_run_ecc_pm_cmd()
2341 ret = ccp_reverse_set_dm_area(&src, 0, ecc->u.pm.point_2.y, 0, in ccp_run_ecc_pm_cmd()
2342 ecc->u.pm.point_2.y_len); in ccp_run_ecc_pm_cmd()
2352 ret = ccp_reverse_set_dm_area(&src, 0, ecc->u.pm.domain_a, 0, in ccp_run_ecc_pm_cmd()
2353 ecc->u.pm.domain_a_len); in ccp_run_ecc_pm_cmd()
2361 ecc->u.pm.scalar, 0, in ccp_run_ecc_pm_cmd()
2362 ecc->u.pm.scalar_len); in ccp_run_ecc_pm_cmd()
2379 op.src.u.dma.address = src.dma.address; in ccp_run_ecc_pm_cmd()
2380 op.src.u.dma.offset = 0; in ccp_run_ecc_pm_cmd()
2381 op.src.u.dma.length = src.length; in ccp_run_ecc_pm_cmd()
2382 op.dst.u.dma.address = dst.dma.address; in ccp_run_ecc_pm_cmd()
2383 op.dst.u.dma.offset = 0; in ccp_run_ecc_pm_cmd()
2384 op.dst.u.dma.length = dst.length; in ccp_run_ecc_pm_cmd()
2386 op.u.ecc.function = cmd->u.ecc.function; in ccp_run_ecc_pm_cmd()
2407 ccp_reverse_get_dm_area(&dst, 0, ecc->u.pm.result.x, 0, in ccp_run_ecc_pm_cmd()
2410 ccp_reverse_get_dm_area(&dst, 0, ecc->u.pm.result.y, 0, in ccp_run_ecc_pm_cmd()
2429 struct ccp_ecc_engine *ecc = &cmd->u.ecc; in ccp_run_ecc_cmd()
2464 switch (cmd->u.aes.mode) { in ccp_run_cmd()