linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: davidm@egauge.net (David Mosberger-Tang)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] spi: atmel: Fix DMA-setup for transfers with more than 8 bits per word.
Date: Mon, 19 Oct 2015 14:54:44 -0600	[thread overview]
Message-ID: <1445288084-31805-1-git-send-email-davidm@egauge.net> (raw)

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>
---
 drivers/spi/spi-atmel.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/spi/spi-atmel.c b/drivers/spi/spi-atmel.c
index 04e48e5..855cc56 100644
--- a/drivers/spi/spi-atmel.c
+++ b/drivers/spi/spi-atmel.c
@@ -758,7 +758,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 */
-- 
1.9.1

             reply	other threads:[~2015-10-19 20:54 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-10-19 20:54 David Mosberger-Tang [this message]
2015-10-20 10:22 ` [PATCH] spi: atmel: Fix DMA-setup for transfers with more than 8 bits per word Nicolas Ferre
2015-10-20 10:27   ` Mark Brown
2015-10-20 12:26     ` Nicolas Ferre
2015-10-20 12:26 ` [RESEND PATCH] " Nicolas Ferre
  -- strict thread matches above, loose matches on Subject: below --
2015-10-19 20:48 [PATCH] " David Mosberger-Tang

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1445288084-31805-1-git-send-email-davidm@egauge.net \
    --to=davidm@egauge.net \
    --cc=linux-arm-kernel@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).