diff options
author | Christian Lamparter <chunkeey@googlemail.com> | 2017-08-25 15:47:19 +0200 |
---|---|---|
committer | Herbert Xu <herbert@gondor.apana.org.au> | 2017-09-22 17:43:17 +0800 |
commit | 453e3090b9c3f5da70b21648c2244e9821f0916d (patch) | |
tree | 8d9b19cec07bbec6826fc894896bf51b931e1a15 /drivers/crypto/amcc/crypto4xx_alg.c | |
parent | c587e65deacf8c86de2d7c51f1e81d0a4a9147a8 (diff) |
crypto: crypto4xx - fix dynamic_sa_ctl's sa_contents declaration
The driver had a union dynamic_sa_contents in place that
described the meaning of the bits in the sa_contents
variable.
Signed-off-by: Christian Lamparter <chunkeey@googlemail.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'drivers/crypto/amcc/crypto4xx_alg.c')
-rw-r--r-- | drivers/crypto/amcc/crypto4xx_alg.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/crypto/amcc/crypto4xx_alg.c b/drivers/crypto/amcc/crypto4xx_alg.c index 6da92321173b..867a9230cd3f 100644 --- a/drivers/crypto/amcc/crypto4xx_alg.c +++ b/drivers/crypto/amcc/crypto4xx_alg.c @@ -149,7 +149,7 @@ static int crypto4xx_setkey_aes(struct crypto_ablkcipher *cipher, SA_NOT_COPY_HDR); crypto4xx_memcpy_le(ctx->sa_in + get_dynamic_sa_offset_key_field(ctx), key, keylen); - sa->sa_contents = SA_AES_CONTENTS | (keylen << 2); + sa->sa_contents.w = SA_AES_CONTENTS | (keylen << 2); sa->sa_command_1.bf.key_len = keylen >> 3; ctx->is_hash = 0; ctx->direction = DIR_INBOUND; @@ -219,7 +219,7 @@ static int crypto4xx_hash_alg_init(struct crypto_tfm *tfm, SA_NOT_COPY_PAD, SA_NOT_COPY_PAYLOAD, SA_NOT_COPY_HDR); ctx->direction = DIR_INBOUND; - sa->sa_contents = SA_HASH160_CONTENTS; + sa->sa_contents.w = SA_HASH160_CONTENTS; sa_in = (struct dynamic_sa_hash160 *) ctx->sa_in; /* Need to zero hash digest in SA */ memset(sa_in->inner_digest, 0, sizeof(sa_in->inner_digest)); |