summaryrefslogtreecommitdiff
path: root/drivers/crypto/caam
diff options
context:
space:
mode:
authorTudor Ambarus <tudor.ambarus@freescale.com>2014-04-03 11:20:33 (GMT)
committerJose Rivera <German.Rivera@freescale.com>2014-04-18 03:53:06 (GMT)
commitdd59512b3f878de0a0abd44f2f514e2c1a3d9848 (patch)
tree57c1a60e8a0854f6e1c0bfe23c5c5f0ffd242e10 /drivers/crypto/caam
parent5833b1aa8d7bae2c265dc27554634b62b064e698 (diff)
downloadlinux-fsl-qoriq-dd59512b3f878de0a0abd44f2f514e2c1a3d9848.tar.xz
crypto: caam/qi - fix condition for the jump over keys command
Only one DECO can access a given shared CHA, so waiting for CHAs to be done is not necessary when jumping the keys. SELF condition has no sense for the SERIAL sharing since the jobs are executed in the same DECO. Change-Id: I83935bcaa5a30c6d78f6cd5234d4bc80b5292b00 Signed-off-by: Tudor Ambarus <tudor.ambarus@freescale.com> Reviewed-on: http://git.am.freescale.net:8181/10815 Tested-by: Review Code-CDREVIEW <CDREVIEW@freescale.com> Reviewed-by: Horia Ioan Geanta Neag <horia.geanta@freescale.com> Reviewed-by: Jose Rivera <German.Rivera@freescale.com>
Diffstat (limited to 'drivers/crypto/caam')
-rw-r--r--drivers/crypto/caam/caamalg_qi.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/drivers/crypto/caam/caamalg_qi.c b/drivers/crypto/caam/caamalg_qi.c
index 7eb95b9..3dac8d1 100644
--- a/drivers/crypto/caam/caamalg_qi.c
+++ b/drivers/crypto/caam/caamalg_qi.c
@@ -411,9 +411,8 @@ static int tls_set_sh_desc(struct crypto_aead *aead)
init_sh_desc(desc, HDR_SHARE_SERIAL | stidx);
/* skip key loading if they are loaded due to sharing */
- key_jump_cmd = append_jump(desc, JUMP_CLASS_BOTH | JUMP_JSL |
- JUMP_TEST_ALL | JUMP_COND_SHRD |
- JUMP_COND_SELF);
+ key_jump_cmd = append_jump(desc, JUMP_JSL | JUMP_TEST_ALL |
+ JUMP_COND_SHRD);
if (keys_fit_inline) {
append_key_as_imm(desc, ctx->key, ctx->split_key_pad_len,
ctx->split_key_len, CLASS_2 |
@@ -506,9 +505,8 @@ static int tls_set_sh_desc(struct crypto_aead *aead)
init_sh_desc(desc, HDR_SHARE_SERIAL | stidx);
/* skip key loading if they are loaded due to sharing */
- key_jump_cmd = append_jump(desc, JUMP_CLASS_BOTH | JUMP_JSL |
- JUMP_TEST_ALL | JUMP_COND_SHRD |
- JUMP_COND_SELF);
+ key_jump_cmd = append_jump(desc, JUMP_JSL | JUMP_TEST_ALL |
+ JUMP_COND_SHRD);
append_key(desc, ctx->key_dma, ctx->split_key_len, CLASS_2 |
KEY_DEST_MDHA_SPLIT | KEY_ENC);
append_key(desc, ctx->key_dma + ctx->split_key_pad_len,