crypto: ixp4xx - dma_unmap the correct address
authorCorentin Labbe <clabbe@baylibre.com>
Wed, 5 May 2021 20:26:08 +0000 (20:26 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 14 Jul 2021 14:56:03 +0000 (16:56 +0200)
commitf00454ac40f87fda875252d1b22e0876512d4414
tree586837ff16dc28a2501ccac275a03d531d783b5b
parent2c3164f31a4963d4b267cf5dc97a23103c4e056d
crypto: ixp4xx - dma_unmap the correct address

[ Upstream commit 9395c58fdddd79cdd3882132cdd04e8ac7ad525f ]

Testing ixp4xx_crypto with CONFIG_DMA_API_DEBUG lead to the following error:
DMA-API: platform ixp4xx_crypto.0: device driver tries to free DMA memory it has not allocated [device address=0x0000000000000000] [size=24 bytes]

This is due to dma_unmap using the wrong address.

Fixes: 0d44dc59b2b4 ("crypto: ixp4xx - Fix handling of chained sg buffers")
Signed-off-by: Corentin Labbe <clabbe@baylibre.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/crypto/ixp4xx_crypto.c