diff options
author | Andy Shevchenko <andriy.shevchenko@linux.intel.com> | 2012-09-21 08:05:48 -0400 |
---|---|---|
committer | Vinod Koul <vinod.koul@linux.intel.com> | 2012-09-27 06:05:23 -0400 |
commit | a09820043c9e11149145a1ec221eed4a7b42dcce (patch) | |
tree | 0561b70b0803aec4b57e41e90fa0ece433f9d59f /drivers/dma/dw_dmac_regs.h | |
parent | 4a63a8b3e8d2e4f56174deb728085010aa3ac2a1 (diff) |
dw_dmac: autoconfigure data_width or get it via platform data
Not all of the controllers support the 64 bit data width. Make it configurable
via platform data. The driver will try to get a value from the component
parameters, otherwise it will use the platform data.
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Acked-by: Viresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: Vinod Koul <vinod.koul@linux.intel.com>
Diffstat (limited to 'drivers/dma/dw_dmac_regs.h')
-rw-r--r-- | drivers/dma/dw_dmac_regs.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/dma/dw_dmac_regs.h b/drivers/dma/dw_dmac_regs.h index 2a1cc533f0c8..06f03914f022 100644 --- a/drivers/dma/dw_dmac_regs.h +++ b/drivers/dma/dw_dmac_regs.h | |||
@@ -198,6 +198,9 @@ struct dw_dma_chan { | |||
198 | 198 | ||
199 | /* configuration passed via DMA_SLAVE_CONFIG */ | 199 | /* configuration passed via DMA_SLAVE_CONFIG */ |
200 | struct dma_slave_config dma_sconfig; | 200 | struct dma_slave_config dma_sconfig; |
201 | |||
202 | /* backlink to dw_dma */ | ||
203 | struct dw_dma *dw; | ||
201 | }; | 204 | }; |
202 | 205 | ||
203 | static inline struct dw_dma_chan_regs __iomem * | 206 | static inline struct dw_dma_chan_regs __iomem * |
@@ -224,6 +227,10 @@ struct dw_dma { | |||
224 | 227 | ||
225 | u8 all_chan_mask; | 228 | u8 all_chan_mask; |
226 | 229 | ||
230 | /* hardware configuration */ | ||
231 | unsigned char nr_masters; | ||
232 | unsigned char data_width[4]; | ||
233 | |||
227 | struct dw_dma_chan chan[0]; | 234 | struct dw_dma_chan chan[0]; |
228 | }; | 235 | }; |
229 | 236 | ||