add dts demo code for spi devices
[firefly-linux-kernel-4.4.55.git] / drivers / spi / spi-davinci.c
index 50b13c9b1ab691fd5defcae44b98dc4bfccb5557..df0aacc6fc3b496f47eda7f96f0cb58954f844a9 100644 (file)
@@ -610,7 +610,7 @@ static int davinci_spi_bufs(struct spi_device *spi, struct spi_transfer *t)
                else
                        buf = (void *)t->tx_buf;
                t->tx_dma = dma_map_single(&spi->dev, buf,
-                               t->len, DMA_FROM_DEVICE);
+                               t->len, DMA_TO_DEVICE);
                if (!t->tx_dma) {
                        ret = -EFAULT;
                        goto err_tx_map;