dmaengine: mv_xor: Use correct device for DMA API
Hello Robin,
Thanks a lot for fixing this!
Quoted 9 lines · On Mon, 18 Feb 2019 18:27:06 +0000 Robin Murphy <[email protected]> wrote:
Using
dma_dev->devfor mappings before it's assigned with the correct device is unlikely to work as expected, and with future dma-direct changes, passing a NULL device may end up crashing entirely. I don't know enough about this hardware or themv_xor_prep_dma_interrupt()operation to implement the appropriate error-handling logic that would have revealed thosedma_map_single()calls failing on arm64 for as long as the driver has been enabled there, but moving the assignment earlier will at least make the current code operate as intended.
Quoted 4 lines
Fixes 22843545b200 ("dma: mv_xor: Add support for DMA_INTERRUPT")Reported-by John David Anglin <[email protected]>Tested-by John David Anglin <[email protected]>Signed-off-by Robin Murphy <[email protected]>
Acked-by Thomas Petazzoni <[email protected]>
Tested-by Thomas Petazzoni <[email protected]>
Best regards,
Thomas