aboutsummaryrefslogtreecommitdiffstats
path: root/arch/blackfin/include/asm/dma.h
diff options
context:
space:
mode:
authorMike Frysinger <vapier.adi@gmail.com>2009-01-07 10:14:38 -0500
committerBryan Wu <cooloney@kernel.org>2009-01-07 10:14:38 -0500
commit6ab729d82f1fa1f7d9896be1bd689ee2a1f17860 (patch)
tree71d55e360d40252ddef5d700f4a082a6ecb177e4 /arch/blackfin/include/asm/dma.h
parent9c417a43299edc52931712a54c46cff4db19082c (diff)
Blackfin arch: desc_ptr is a pointer, so declare it as such
Signed-off-by: Mike Frysinger <vapier.adi@gmail.com> Signed-off-by: Bryan Wu <cooloney@kernel.org>
Diffstat (limited to 'arch/blackfin/include/asm/dma.h')
-rw-r--r--arch/blackfin/include/asm/dma.h16
1 files changed, 8 insertions, 8 deletions
diff --git a/arch/blackfin/include/asm/dma.h b/arch/blackfin/include/asm/dma.h
index 690c25f5f992..264feb4eb175 100644
--- a/arch/blackfin/include/asm/dma.h
+++ b/arch/blackfin/include/asm/dma.h
@@ -52,7 +52,7 @@ enum dma_chan_status {
52#define DMA_SYNC_RESTART 1 52#define DMA_SYNC_RESTART 1
53 53
54struct dmasg { 54struct dmasg {
55 unsigned long next_desc_addr; 55 void *next_desc_addr;
56 unsigned long start_addr; 56 unsigned long start_addr;
57 unsigned short cfg; 57 unsigned short cfg;
58 unsigned short x_count; 58 unsigned short x_count;
@@ -62,7 +62,7 @@ struct dmasg {
62} __attribute__((packed)); 62} __attribute__((packed));
63 63
64struct dma_register { 64struct dma_register {
65 unsigned long next_desc_ptr; /* DMA Next Descriptor Pointer register */ 65 void *next_desc_ptr; /* DMA Next Descriptor Pointer register */
66 unsigned long start_addr; /* DMA Start address register */ 66 unsigned long start_addr; /* DMA Start address register */
67 67
68 unsigned short cfg; /* DMA Configuration register */ 68 unsigned short cfg; /* DMA Configuration register */
@@ -82,7 +82,7 @@ struct dma_register {
82 short y_modify; /* DMA y_modify register */ 82 short y_modify; /* DMA y_modify register */
83 unsigned short dummy5; 83 unsigned short dummy5;
84 84
85 unsigned long curr_desc_ptr; /* DMA Current Descriptor Pointer 85 void *curr_desc_ptr; /* DMA Current Descriptor Pointer
86 register */ 86 register */
87 unsigned long curr_addr_ptr; /* DMA Current Address Pointer 87 unsigned long curr_addr_ptr; /* DMA Current Address Pointer
88 register */ 88 register */
@@ -137,11 +137,11 @@ static inline void set_dma_start_addr(unsigned int channel, unsigned long addr)
137{ 137{
138 dma_ch[channel].regs->start_addr = addr; 138 dma_ch[channel].regs->start_addr = addr;
139} 139}
140static inline void set_dma_next_desc_addr(unsigned int channel, unsigned long addr) 140static inline void set_dma_next_desc_addr(unsigned int channel, void *addr)
141{ 141{
142 dma_ch[channel].regs->next_desc_ptr = addr; 142 dma_ch[channel].regs->next_desc_ptr = addr;
143} 143}
144static inline void set_dma_curr_desc_addr(unsigned int channel, unsigned long addr) 144static inline void set_dma_curr_desc_addr(unsigned int channel, void *addr)
145{ 145{
146 dma_ch[channel].regs->curr_desc_ptr = addr; 146 dma_ch[channel].regs->curr_desc_ptr = addr;
147} 147}
@@ -190,11 +190,11 @@ static inline unsigned short get_dma_curr_ycount(unsigned int channel)
190{ 190{
191 return dma_ch[channel].regs->curr_y_count; 191 return dma_ch[channel].regs->curr_y_count;
192} 192}
193static inline unsigned long get_dma_next_desc_ptr(unsigned int channel) 193static inline void *get_dma_next_desc_ptr(unsigned int channel)
194{ 194{
195 return dma_ch[channel].regs->next_desc_ptr; 195 return dma_ch[channel].regs->next_desc_ptr;
196} 196}
197static inline unsigned long get_dma_curr_desc_ptr(unsigned int channel) 197static inline void *get_dma_curr_desc_ptr(unsigned int channel)
198{ 198{
199 return dma_ch[channel].regs->curr_desc_ptr; 199 return dma_ch[channel].regs->curr_desc_ptr;
200} 200}
@@ -206,7 +206,7 @@ static inline unsigned long get_dma_curr_addr(unsigned int channel)
206static inline void set_dma_sg(unsigned int channel, struct dmasg *sg, int ndsize) 206static inline void set_dma_sg(unsigned int channel, struct dmasg *sg, int ndsize)
207{ 207{
208 dma_ch[channel].regs->cfg |= ((ndsize & 0x0F) << 8); 208 dma_ch[channel].regs->cfg |= ((ndsize & 0x0F) << 8);
209 dma_ch[channel].regs->next_desc_ptr = (unsigned long)sg; 209 dma_ch[channel].regs->next_desc_ptr = sg;
210} 210}
211 211
212static inline int dma_channel_active(unsigned int channel) 212static inline int dma_channel_active(unsigned int channel)