crypto: sahara - fix error handling in sahara_hw_descriptor_create()

[ Upstream commit ee6e6f0a7f ]

Do not call dma_unmap_sg() for scatterlists that were not mapped
successfully.

Fixes: 5de8875281 ("crypto: sahara - Add driver for SAHARA2 accelerator.")
Signed-off-by: Ovidiu Panait <ovidiu.panait@windriver.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
Ovidiu Panait 2023-12-01 19:06:23 +02:00 • committed by Greg Kroah-Hartman
commit d1f82d7210