]> git.baikalelectronics.ru Git - kernel.git/commit
crypto: mxs-dcp - fix scatterlist linearization for hash
authorRosioru Dragos <dragos.rosioru@nxp.com>
Tue, 25 Feb 2020 15:05:52 +0000 (17:05 +0200)
committerHerbert Xu <herbert@gondor.apana.org.au>
Fri, 6 Mar 2020 01:28:21 +0000 (12:28 +1100)
commit4a7c0fc2abede55b98be67d898af07efb02dd8be
treec0446b88eae61a4639fd3d7d24fdc48021113375
parent0bcd79e730783301d930c23f3c511328acd88069
crypto: mxs-dcp - fix scatterlist linearization for hash

The incorrect traversal of the scatterlist, during the linearization phase
lead to computing the hash value of the wrong input buffer.
New implementation uses scatterwalk_map_and_copy()
to address this issue.

Cc: <stable@vger.kernel.org>
Fixes: c70576caacbf ("crypto: mxs - Add Freescale MXS DCP driver")
Signed-off-by: Rosioru Dragos <dragos.rosioru@nxp.com>
Reviewed-by: Horia Geantă <horia.geanta@nxp.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
drivers/crypto/mxs-dcp.c