Skip to content
Commit 29213b5e authored by Declan Snyder's avatar Declan Snyder Committed by Benjamin Cabé
Browse files

spi_nxp_lpspi: Fix DMA driver async return



We should not release context until transfer ends. The code previously
would return from wait_for_completion and then release the context. This
is only supposed to be done in the dma callback except for the case of
error in the transceive call. For async transfer this was most likely
always happening wrong and probably broken for multi threads trying to
access the bus due to this premature release of the context.

Also we should not enable CS and leave enabled in case of error, move CS
enable to after the error check.

Signed-off-by: default avatarDeclan Snyder <declan.snyder@nxp.com>
parent 5acee4ad
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment