summaryrefslogtreecommitdiffstats
path: root/drivers/spi/spi-dw.h
diff options
context:
space:
mode:
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>2015-03-09 16:48:46 +0200
committerMark Brown <broonie@kernel.org>2015-03-09 18:11:13 +0000
commit9f14538ecd1a210eff244a0a2281f6744fe4a59d (patch)
tree3fbe4c565d59def0182e970ab19e039d55c66ebf /drivers/spi/spi-dw.h
parente31abce778bc05b94d406e8cbebd9953d12e84b8 (diff)
downloadtalos-obmc-linux-9f14538ecd1a210eff244a0a2281f6744fe4a59d.tar.gz
talos-obmc-linux-9f14538ecd1a210eff244a0a2281f6744fe4a59d.zip
spi: dw-mid: split dma_setup() from dma_transfer()
The patch splits DMA preparatory code to dma_setup() callback. The change also converts transfer_one() to program DMA whenever the transfer is DMA mapped. The change is a follow up of the converion to use SPI core transfer_one_message(). Since the DMA mapped transfers can be interleaved with PIO ones the DMA related configuration should respect that. Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'drivers/spi/spi-dw.h')
-rw-r--r--drivers/spi/spi-dw.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/spi/spi-dw.h b/drivers/spi/spi-dw.h
index 855bfdd7b433..7351692494ec 100644
--- a/drivers/spi/spi-dw.h
+++ b/drivers/spi/spi-dw.h
@@ -91,7 +91,8 @@ struct dw_spi;
struct dw_spi_dma_ops {
int (*dma_init)(struct dw_spi *dws);
void (*dma_exit)(struct dw_spi *dws);
- int (*dma_transfer)(struct dw_spi *dws, int cs_change);
+ int (*dma_setup)(struct dw_spi *dws);
+ int (*dma_transfer)(struct dw_spi *dws);
};
struct dw_spi {
@@ -109,7 +110,6 @@ struct dw_spi {
u16 num_cs; /* supported slave numbers */
/* Current message transfer state info */
- struct chip_data *prev_chip;
size_t len;
void *tx;
void *tx_end;
OpenPOWER on IntegriCloud