aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/spi/spi-dw-mid.c
diff options
context:
space:
mode:
authorVinod Koul <vinod.koul@linux.intel.com>2011-10-14 01:17:38 -0400
committerVinod Koul <vinod.koul@linux.intel.com>2011-10-31 00:10:26 -0400
commita485df4b4404379786c4bdd258bc528b2617449d (patch)
tree67244495fab89846568cf40d3b7c3a2bd011133e /drivers/spi/spi-dw-mid.c
parent05f5799cbe5c9e2c03f604b3de5783cf4d726227 (diff)
spi, serial: move to dma_transfer_direction
fixup usage of dma direction by introducing dma_transfer_direction, this patch moves spi, serial drivers to use new enum Signed-off-by: Vinod Koul <vinod.koul@linux.intel.com> Cc: Grant Likely <grant.likely@secretlab.ca> Cc: Alan Cox <alan@linux.intel.com> Acked-by: Mika Westerberg <mika.westerberg@iki.fi>
Diffstat (limited to 'drivers/spi/spi-dw-mid.c')
-rw-r--r--drivers/spi/spi-dw-mid.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/spi/spi-dw-mid.c b/drivers/spi/spi-dw-mid.c
index 130e55537db6..0a1fc8a27e3d 100644
--- a/drivers/spi/spi-dw-mid.c
+++ b/drivers/spi/spi-dw-mid.c
@@ -131,7 +131,7 @@ static int mid_spi_dma_transfer(struct dw_spi *dws, int cs_change)
131 rxchan = dws->rxchan; 131 rxchan = dws->rxchan;
132 132
133 /* 2. Prepare the TX dma transfer */ 133 /* 2. Prepare the TX dma transfer */
134 txconf.direction = DMA_TO_DEVICE; 134 txconf.direction = DMA_MEM_TO_DEV;
135 txconf.dst_addr = dws->dma_addr; 135 txconf.dst_addr = dws->dma_addr;
136 txconf.dst_maxburst = LNW_DMA_MSIZE_16; 136 txconf.dst_maxburst = LNW_DMA_MSIZE_16;
137 txconf.src_addr_width = DMA_SLAVE_BUSWIDTH_4_BYTES; 137 txconf.src_addr_width = DMA_SLAVE_BUSWIDTH_4_BYTES;
@@ -147,13 +147,13 @@ static int mid_spi_dma_transfer(struct dw_spi *dws, int cs_change)
147 txdesc = txchan->device->device_prep_slave_sg(txchan, 147 txdesc = txchan->device->device_prep_slave_sg(txchan,
148 &dws->tx_sgl, 148 &dws->tx_sgl,
149 1, 149 1,
150 DMA_TO_DEVICE, 150 DMA_MEM_TO_DEV,
151 DMA_PREP_INTERRUPT | DMA_COMPL_SKIP_DEST_UNMAP); 151 DMA_PREP_INTERRUPT | DMA_COMPL_SKIP_DEST_UNMAP);
152 txdesc->callback = dw_spi_dma_done; 152 txdesc->callback = dw_spi_dma_done;
153 txdesc->callback_param = dws; 153 txdesc->callback_param = dws;
154 154
155 /* 3. Prepare the RX dma transfer */ 155 /* 3. Prepare the RX dma transfer */
156 rxconf.direction = DMA_FROM_DEVICE; 156 rxconf.direction = DMA_DEV_TO_MEM;
157 rxconf.src_addr = dws->dma_addr; 157 rxconf.src_addr = dws->dma_addr;
158 rxconf.src_maxburst = LNW_DMA_MSIZE_16; 158 rxconf.src_maxburst = LNW_DMA_MSIZE_16;
159 rxconf.dst_addr_width = DMA_SLAVE_BUSWIDTH_4_BYTES; 159 rxconf.dst_addr_width = DMA_SLAVE_BUSWIDTH_4_BYTES;
@@ -169,7 +169,7 @@ static int mid_spi_dma_transfer(struct dw_spi *dws, int cs_change)
169 rxdesc = rxchan->device->device_prep_slave_sg(rxchan, 169 rxdesc = rxchan->device->device_prep_slave_sg(rxchan,
170 &dws->rx_sgl, 170 &dws->rx_sgl,
171 1, 171 1,
172 DMA_FROM_DEVICE, 172 DMA_DEV_TO_MEM,
173 DMA_PREP_INTERRUPT | DMA_COMPL_SKIP_DEST_UNMAP); 173 DMA_PREP_INTERRUPT | DMA_COMPL_SKIP_DEST_UNMAP);
174 rxdesc->callback = dw_spi_dma_done; 174 rxdesc->callback = dw_spi_dma_done;
175 rxdesc->callback_param = dws; 175 rxdesc->callback_param = dws;