summaryrefslogtreecommitdiff
path: root/drivers/spi/spi-sh-msiof.c
diff options
context:
space:
mode:
authorGeert Uytterhoeven <geert+renesas@glider.be>2014-08-07 14:07:43 +0200
committerMark Brown <broonie@linaro.org>2014-08-16 17:14:30 -0500
commit7a9f957b395fc08edc47620c01e8bb5b798caddb (patch)
tree338e9290ea716ec65b77fabd978c2fcc4f502ec1 /drivers/spi/spi-sh-msiof.c
parenta5e7c719fe257214aeda3dadb502a4cf58209a61 (diff)
downloadlwn-7a9f957b395fc08edc47620c01e8bb5b798caddb.tar.gz
lwn-7a9f957b395fc08edc47620c01e8bb5b798caddb.zip
spi: sh-msiof: Fix transmit-only DMA transfers
Fix tx/rx mixup, which broke transmit-only transfers. Introduced by commit 4240305f7cbdc7782aa8bc40cc702775d9ac0839 ("spi: sh-msiof: Fix leaking of unused DMA descriptors"). Reported-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Acked-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by: Mark Brown <broonie@linaro.org>
Diffstat (limited to 'drivers/spi/spi-sh-msiof.c')
-rw-r--r--drivers/spi/spi-sh-msiof.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/spi/spi-sh-msiof.c b/drivers/spi/spi-sh-msiof.c
index daaa868e959f..1165d418340f 100644
--- a/drivers/spi/spi-sh-msiof.c
+++ b/drivers/spi/spi-sh-msiof.c
@@ -689,9 +689,9 @@ static int sh_msiof_dma_once(struct sh_msiof_spi_priv *p, const void *tx,
reinit_completion(&p->done);
/* Now start DMA */
- if (tx)
- dma_async_issue_pending(p->master->dma_rx);
if (rx)
+ dma_async_issue_pending(p->master->dma_rx);
+ if (tx)
dma_async_issue_pending(p->master->dma_tx);
ret = sh_msiof_spi_start(p, rx);