crypto: stm32/crc32 - fix run-time self test issue.
authorNicolas Toromanoff <nicolas.toromanoff@st.com>
Tue, 12 May 2020 14:11:10 +0000 (16:11 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 22 Jun 2020 07:31:07 +0000 (09:31 +0200)
commitd879598b8dae00da888dd957c913bd0f9687f42a
treed9c36b898c32d05b2afc217705bb7b62b5b8c5f2
parent8fe61a2027db269c563fb632dec79a55081b8d99
crypto: stm32/crc32 - fix run-time self test issue.

[ Upstream commit a8cc3128bf2c01c4d448fe17149e87132113b445 ]

Fix wrong crc32 initialisation value:
"alg: shash: stm32_crc32 test failed (wrong result) on test vector 0,
cfg="init+update+final aligned buffer"
cra_name="crc32c" expects an init value of 0XFFFFFFFF,
cra_name="crc32" expects an init value of 0.

Fixes: b51dbe90912a ("crypto: stm32 - Support for STM32 CRC32 crypto module")

Signed-off-by: Nicolas Toromanoff <nicolas.toromanoff@st.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/crypto/stm32/stm32-crc32.c