diff options
author | Sonic Zhang <sonic.zhang@analog.com> | 2007-08-05 16:14:58 +0800 |
---|---|---|
committer | Bryan Wu <bryan.wu@analog.com> | 2007-08-05 16:14:58 +0800 |
commit | 8a26ac7043b0cb3b446ad9f9a3ec0992d0fea1f7 (patch) | |
tree | 27134ed1c717e041d5f1f5d60375deb899ce2457 /arch/blackfin/kernel/bfin_dma_5xx.c | |
parent | 2cbfe107434b9651168afb21015f3285e02beed3 (diff) | |
download | linux-8a26ac7043b0cb3b446ad9f9a3ec0992d0fea1f7.tar.gz linux-8a26ac7043b0cb3b446ad9f9a3ec0992d0fea1f7.tar.bz2 linux-8a26ac7043b0cb3b446ad9f9a3ec0992d0fea1f7.zip |
Blackfin arch: Add DMA API to set curr descriptor address
This API is necessary for DMA descriptor array mode.
Signed-off-by: Sonic Zhang <sonic.zhang@analog.com>
Signed-off-by: Bryan Wu <bryan.wu@analog.com>
Diffstat (limited to 'arch/blackfin/kernel/bfin_dma_5xx.c')
-rw-r--r-- | arch/blackfin/kernel/bfin_dma_5xx.c | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/arch/blackfin/kernel/bfin_dma_5xx.c b/arch/blackfin/kernel/bfin_dma_5xx.c index 62f5a35c13ee..f0db6c5c8d1a 100644 --- a/arch/blackfin/kernel/bfin_dma_5xx.c +++ b/arch/blackfin/kernel/bfin_dma_5xx.c @@ -270,10 +270,23 @@ void set_dma_next_desc_addr(unsigned int channel, unsigned long addr) dma_ch[channel].regs->next_desc_ptr = addr; SSYNC(); - pr_debug("set_dma_start_addr() : END\n"); + pr_debug("set_dma_next_desc_addr() : END\n"); } EXPORT_SYMBOL(set_dma_next_desc_addr); +void set_dma_curr_desc_addr(unsigned int channel, unsigned long addr) +{ + pr_debug("set_dma_curr_desc_addr() : BEGIN \n"); + + BUG_ON(!(dma_ch[channel].chan_status != DMA_CHANNEL_FREE + && channel < MAX_BLACKFIN_DMA_CHANNEL)); + + dma_ch[channel].regs->curr_desc_ptr = addr; + SSYNC(); + pr_debug("set_dma_curr_desc_addr() : END\n"); +} +EXPORT_SYMBOL(set_dma_curr_desc_addr); + void set_dma_x_count(unsigned int channel, unsigned short x_count) { BUG_ON(!(dma_ch[channel].chan_status != DMA_CHANNEL_FREE |