crypto: brcm - explicitly cast cipher to hash type
authorStefan Agner <stefan@agner.ch>
Sat, 24 Mar 2018 11:02:42 +0000 (12:02 +0100)
committerHerbert Xu <herbert@gondor.apana.org.au>
Fri, 30 Mar 2018 17:33:14 +0000 (01:33 +0800)
commita2e5d408a46372b8fba9b1af592edc6fa3fc93a9
treefa71fafe6482cfac3ab76b08fa7e5759648fe5aa
parent8f0691fc51e1ce06ccfccb7336320331a9521b9d
crypto: brcm - explicitly cast cipher to hash type

In the AES cases enum spu_cipher_type and enum hash_type have
the same values, so the assignment is fine. Explicitly cast
the enum type conversion.

This fixes two warnings when building with clang:
  drivers/crypto/bcm/cipher.c:821:34: warning: implicit conversion from
      enumeration type 'enum spu_cipher_type' to different enumeration
      type 'enum hash_type' [-Wenum-conversion]
                hash_parms.type = cipher_parms.type;
                                ~ ~~~~~~~~~~~~~^~~~
  drivers/crypto/bcm/cipher.c:1412:26: warning: implicit conversion from
      enumeration type 'enum spu_cipher_type' to different enumeration
      type 'enum hash_type' [-Wenum-conversion]
                hash_parms.type = ctx->cipher_type;
                                ~ ~~~~~^~~~~~~~~~~

Signed-off-by: Stefan Agner <stefan@agner.ch>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
drivers/crypto/bcm/cipher.c