diff options
author | Frode Isaksen | 2017-03-17 16:41:10 +0100 |
---|---|---|
committer | Mark Brown | 2017-03-17 23:00:51 +0100 |
commit | 1234e8398fe03267bf2e353e36825dbd0abc2fc6 (patch) | |
tree | 6ecedf5fbb11175762f7506032ed33dce32e40da /drivers/spi | |
parent | spi: davinci: do not use DMA for vmalloc'ed buffers (diff) | |
download | kernel-qcow2-linux-1234e8398fe03267bf2e353e36825dbd0abc2fc6.tar.gz kernel-qcow2-linux-1234e8398fe03267bf2e353e36825dbd0abc2fc6.tar.xz kernel-qcow2-linux-1234e8398fe03267bf2e353e36825dbd0abc2fc6.zip |
spi: davinci: add comment about dummy tx buffer usage
Add explanation about using the the rx buffer as the
dummy tx buffer.
Signed-off-by: Frode Isaksen <fisaksen@baylibre.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'drivers/spi')
-rw-r--r-- | drivers/spi/spi-davinci.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/drivers/spi/spi-davinci.c b/drivers/spi/spi-davinci.c index f37bbdd18d61..595acdcfc7d0 100644 --- a/drivers/spi/spi-davinci.c +++ b/drivers/spi/spi-davinci.c @@ -660,7 +660,11 @@ static int davinci_spi_bufs(struct spi_device *spi, struct spi_transfer *t) goto err_desc; if (!t->tx_buf) { - /* use rx buffer as dummy tx buffer */ + /* To avoid errors when doing rx-only transfers with + * many SG entries (> 20), use the rx buffer as the + * dummy tx buffer so that dma reloads are done at the + * same time for rx and tx. + */ t->tx_sg.sgl = t->rx_sg.sgl; t->tx_sg.nents = t->rx_sg.nents; } |