diff options
-rw-r--r-- | drivers/dma/amba-pl08x.c | 4 | ||||
-rw-r--r-- | include/linux/amba/pl08x.h | 8 |
2 files changed, 7 insertions, 5 deletions
diff --git a/drivers/dma/amba-pl08x.c b/drivers/dma/amba-pl08x.c index 840c6c0dc533..513184b4fdd1 100644 --- a/drivers/dma/amba-pl08x.c +++ b/drivers/dma/amba-pl08x.c | |||
@@ -1139,6 +1139,8 @@ static int dma_set_runtime_config(struct dma_chan *chan, | |||
1139 | cctl |= burst << PL080_CONTROL_SB_SIZE_SHIFT; | 1139 | cctl |= burst << PL080_CONTROL_SB_SIZE_SHIFT; |
1140 | cctl |= burst << PL080_CONTROL_DB_SIZE_SHIFT; | 1140 | cctl |= burst << PL080_CONTROL_DB_SIZE_SHIFT; |
1141 | 1141 | ||
1142 | plchan->device_fc = config->device_fc; | ||
1143 | |||
1142 | if (plchan->runtime_direction == DMA_DEV_TO_MEM) { | 1144 | if (plchan->runtime_direction == DMA_DEV_TO_MEM) { |
1143 | plchan->src_addr = config->src_addr; | 1145 | plchan->src_addr = config->src_addr; |
1144 | plchan->src_cctl = pl08x_cctl(cctl) | PL080_CONTROL_DST_INCR | | 1146 | plchan->src_cctl = pl08x_cctl(cctl) | PL080_CONTROL_DST_INCR | |
@@ -1370,7 +1372,7 @@ static struct dma_async_tx_descriptor *pl08x_prep_slave_sg( | |||
1370 | return NULL; | 1372 | return NULL; |
1371 | } | 1373 | } |
1372 | 1374 | ||
1373 | if (plchan->cd->device_fc) | 1375 | if (plchan->device_fc) |
1374 | tmp = (direction == DMA_MEM_TO_DEV) ? PL080_FLOW_MEM2PER_PER : | 1376 | tmp = (direction == DMA_MEM_TO_DEV) ? PL080_FLOW_MEM2PER_PER : |
1375 | PL080_FLOW_PER2MEM_PER; | 1377 | PL080_FLOW_PER2MEM_PER; |
1376 | else | 1378 | else |
diff --git a/include/linux/amba/pl08x.h b/include/linux/amba/pl08x.h index 033f6aa670de..2c58853ca423 100644 --- a/include/linux/amba/pl08x.h +++ b/include/linux/amba/pl08x.h | |||
@@ -47,9 +47,6 @@ enum { | |||
47 | * @muxval: a number usually used to poke into some mux regiser to | 47 | * @muxval: a number usually used to poke into some mux regiser to |
48 | * mux in the signal to this channel | 48 | * mux in the signal to this channel |
49 | * @cctl_opt: default options for the channel control register | 49 | * @cctl_opt: default options for the channel control register |
50 | * @device_fc: Flow Controller Settings for ccfg register. Only valid for slave | ||
51 | * channels. Fill with 'true' if peripheral should be flow controller. Direction | ||
52 | * will be selected at Runtime. | ||
53 | * @addr: source/target address in physical memory for this DMA channel, | 50 | * @addr: source/target address in physical memory for this DMA channel, |
54 | * can be the address of a FIFO register for burst requests for example. | 51 | * can be the address of a FIFO register for burst requests for example. |
55 | * This can be left undefined if the PrimeCell API is used for configuring | 52 | * This can be left undefined if the PrimeCell API is used for configuring |
@@ -68,7 +65,6 @@ struct pl08x_channel_data { | |||
68 | int max_signal; | 65 | int max_signal; |
69 | u32 muxval; | 66 | u32 muxval; |
70 | u32 cctl; | 67 | u32 cctl; |
71 | bool device_fc; | ||
72 | dma_addr_t addr; | 68 | dma_addr_t addr; |
73 | bool circular_buffer; | 69 | bool circular_buffer; |
74 | bool single; | 70 | bool single; |
@@ -183,6 +179,9 @@ enum pl08x_dma_chan_state { | |||
183 | * @host: a pointer to the host (internal use) | 179 | * @host: a pointer to the host (internal use) |
184 | * @state: whether the channel is idle, paused, running etc | 180 | * @state: whether the channel is idle, paused, running etc |
185 | * @slave: whether this channel is a device (slave) or for memcpy | 181 | * @slave: whether this channel is a device (slave) or for memcpy |
182 | * @device_fc: Flow Controller Settings for ccfg register. Only valid for slave | ||
183 | * channels. Fill with 'true' if peripheral should be flow controller. Direction | ||
184 | * will be selected at Runtime. | ||
186 | * @waiting: a TX descriptor on this channel which is waiting for a physical | 185 | * @waiting: a TX descriptor on this channel which is waiting for a physical |
187 | * channel to become available | 186 | * channel to become available |
188 | */ | 187 | */ |
@@ -205,6 +204,7 @@ struct pl08x_dma_chan { | |||
205 | struct pl08x_driver_data *host; | 204 | struct pl08x_driver_data *host; |
206 | enum pl08x_dma_chan_state state; | 205 | enum pl08x_dma_chan_state state; |
207 | bool slave; | 206 | bool slave; |
207 | bool device_fc; | ||
208 | struct pl08x_txd *waiting; | 208 | struct pl08x_txd *waiting; |
209 | }; | 209 | }; |
210 | 210 | ||