crypto: omap-sham - clear dma flags only after omap_sham_update_dma_stop()
authorTony Lindgren <tony@atomide.com>
Tue, 27 Jul 2021 10:23:34 +0000 (13:23 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 22 Sep 2021 09:42:58 +0000 (11:42 +0200)
commit624664d15678f387c6e5c09b8148e5f29e76f80b
tree4eb67a02e52d853b0eabd3813e4038c8fa700c09
parent78456f65794dfcee2cd7abf8f8fbb4ce462b243d
crypto: omap-sham - clear dma flags only after omap_sham_update_dma_stop()

[ Upstream commit fe28140b3393b0ba1eb95cc109f974a7e58b26fd ]

We should not clear FLAGS_DMA_ACTIVE before omap_sham_update_dma_stop() is
done calling dma_unmap_sg(). We already clear FLAGS_DMA_ACTIVE at the
end of omap_sham_update_dma_stop().

The early clearing of FLAGS_DMA_ACTIVE is not causing issues as we do not
need to defer anything based on FLAGS_DMA_ACTIVE currently. So this can be
applied as clean-up.

Cc: Lokesh Vutla <lokeshvutla@ti.com>
Cc: Tero Kristo <kristo@kernel.org>
Signed-off-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/crypto/omap-sham.c