linux/drivers/crypto/ccree
Gilad Ben-Yossef c139c72e2b crypto: ccree - unmap buffer before copying IV
We were copying the last ciphertext block into the IV field
for CBC before removing the DMA mapping of the output buffer
with the result of the buffer sometime being out-of-sync cache
wise and were getting intermittent cases of bad output IV.

Fix it by moving the DMA buffer unmapping before the copy.

Signed-off-by: Gilad Ben-Yossef <gilad@benyossef.com>
Fixes: 00904aa0cd ("crypto: ccree - fix iv handling")
Cc: <stable@vger.kernel.org>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
2019-01-25 18:41:51 +08:00
..
cc_aead.c crypto: ccree - convert to use crypto_authenc_extractkeys() 2019-01-10 21:37:31 +08:00
cc_aead.h crypto: ccree - add AEAD support 2018-02-15 23:26:42 +08:00
cc_buffer_mgr.c crypto: ccree - fix free of unallocated mlli buffer 2019-01-25 18:41:51 +08:00
cc_buffer_mgr.h crypto: ccree - add AEAD support 2018-02-15 23:26:42 +08:00
cc_cipher.c crypto: ccree - unmap buffer before copying IV 2019-01-25 18:41:51 +08:00
cc_cipher.h crypto: ccree - remove cipher ivgen left overs 2018-08-03 18:06:05 +08:00
cc_crypto_ctx.h crypto: ccree - add SM3 support 2018-11-09 17:37:58 +08:00
cc_debugfs.c crypto: ccree - correct host regs offset 2018-05-31 00:13:49 +08:00
cc_debugfs.h
cc_driver.c crypto: ccree - add support for CryptoCell 703 2018-12-07 14:14:59 +08:00
cc_driver.h crypto: ccree - remove legacy leftover 2019-01-25 18:41:51 +08:00
cc_fips.c crypto: ccree - add support for older HW revs 2018-03-03 00:03:16 +08:00
cc_fips.h crypto: ccree - add FIPS support 2018-02-15 23:26:42 +08:00
cc_hash.c crypto: ccree - add support for CryptoCell 703 2018-12-07 14:14:59 +08:00
cc_hash.h crypto: ccree - add support for older HW revs 2018-03-03 00:03:16 +08:00
cc_host_regs.h crypto: ccree - correct host regs offset 2018-05-31 00:13:49 +08:00
cc_hw_queue_defs.h crypto: ccree - add SM3 support 2018-11-09 17:37:58 +08:00
cc_ivgen.c
cc_ivgen.h
cc_kernel_regs.h crypto: ccree - add support for older HW revs 2018-03-03 00:03:16 +08:00
cc_lli_defs.h
cc_pm.c crypto: ccree - add ahash support 2018-02-15 23:26:41 +08:00
cc_pm.h
cc_request_mgr.c crypto: ccree - replace memset+kfree with kzfree 2018-03-03 00:03:16 +08:00
cc_request_mgr.h
cc_sram_mgr.c crypto: ccree - add support for older HW revs 2018-03-03 00:03:16 +08:00
cc_sram_mgr.h
Makefile crypto: ccree - add FIPS support 2018-02-15 23:26:42 +08:00