crypto: hisilicon/sec2 - fix some cleanup issues
authorQi Tao <taoqi10@huawei.com>
Fri, 26 Jan 2024 09:38:27 +0000 (17:38 +0800)
committerHerbert Xu <herbert@gondor.apana.org.au>
Fri, 2 Feb 2024 10:10:05 +0000 (18:10 +0800)
commitdd1a502cabcaa410c68ee9f74eae50d85e89fee3
tree7f0409792d5709ee69cbd7c40443e077c00920f6
parentc4af422545474a0dbae1b17d306ec94e32ee0551
crypto: hisilicon/sec2 - fix some cleanup issues

This patch fixes following cleanup issues:
 - The return value of the function is
   inconsistent with the actual return type.
 - After the pointer type is directly converted
   to the `__le64` type, the program may crash
   or produce unexpected results.

Signed-off-by: Qi Tao <taoqi10@huawei.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
drivers/crypto/hisilicon/sec2/sec_crypto.c