Skip to content

Commit

Permalink
spi: img-spfi: Enable controller before starting TX DMA
Browse files Browse the repository at this point in the history
It is recommended that the SPFI controller be enabled (i.e. setting
SPFI_EN in SPFI_CONTROL) before TX DMA begins.

Signed-off-by: Andrew Bresticker <abrestic@chromium.org>
Signed-off-by: Mark Brown <broonie@kernel.org>
  • Loading branch information
Andrew Bresticker authored and Mark Brown committed Dec 22, 2014
1 parent 97bf6af commit c0e7dc2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/spi/spi-img-spfi.c
Original file line number Diff line number Diff line change
Expand Up @@ -390,14 +390,14 @@ static int img_spfi_start_dma(struct spi_master *master,
dma_async_issue_pending(spfi->rx_ch);
}

spfi_start(spfi);

if (xfer->tx_buf) {
spfi->tx_dma_busy = true;
dmaengine_submit(txdesc);
dma_async_issue_pending(spfi->tx_ch);
}

spfi_start(spfi);

return 1;

stop_dma:
Expand Down

0 comments on commit c0e7dc2

Please sign in to comment.