summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorDavid Mosberger-Tang <davidm@egauge.net>2015-10-20 14:26:47 +0200
committerMark Brown <broonie@kernel.org>2015-10-23 01:15:16 +0900
commit06515f83908d038d9e12ffa3dcca27a1b67f2de0 (patch)
treef77b1e2792fb9de4d6e1d540546395604c8929ea /drivers
parent6ff33f3902c3b1c5d0db6b1e2c70b6d76fba357f (diff)
spi: atmel: Fix DMA-setup for transfers with more than 8 bits per word
The DMA-slave configuration depends on the whether <= 8 or > 8 bits are transferred per word, so we need to call atmel_spi_dma_slave_config() with the correct value. Signed-off-by: David Mosberger <davidm@egauge.net> Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> Signed-off-by: Mark Brown <broonie@kernel.org> Cc: stable@vger.kernel.org
Diffstat (limited to 'drivers')
-rw-r--r--drivers/spi/spi-atmel.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/spi/spi-atmel.c b/drivers/spi/spi-atmel.c
index bf9ed380bb1c..41d95a662be7 100644
--- a/drivers/spi/spi-atmel.c
+++ b/drivers/spi/spi-atmel.c
@@ -773,7 +773,8 @@ static int atmel_spi_next_xfer_dma_submit(struct spi_master *master,
*plen = len;
- if (atmel_spi_dma_slave_config(as, &slave_config, 8))
+ if (atmel_spi_dma_slave_config(as, &slave_config,
+ xfer->bits_per_word))
goto err_exit;
/* Send both scatterlists */