diff options
Diffstat (limited to 'firmware/target/arm/imx31/gigabeat-s/pcm-gigabeat-s.c')
-rw-r--r-- | firmware/target/arm/imx31/gigabeat-s/pcm-gigabeat-s.c | 28 |
1 files changed, 0 insertions, 28 deletions
diff --git a/firmware/target/arm/imx31/gigabeat-s/pcm-gigabeat-s.c b/firmware/target/arm/imx31/gigabeat-s/pcm-gigabeat-s.c index 13dff6ecb5..955301b4da 100644 --- a/firmware/target/arm/imx31/gigabeat-s/pcm-gigabeat-s.c +++ b/firmware/target/arm/imx31/gigabeat-s/pcm-gigabeat-s.c | |||
@@ -224,34 +224,6 @@ void pcm_play_dma_stop(void) | |||
224 | play_stop_pcm(); | 224 | play_stop_pcm(); |
225 | } | 225 | } |
226 | 226 | ||
227 | /* Return a pointer to the samples and the number of them in *count */ | ||
228 | const void * pcm_play_dma_get_peak_buffer(int *count) | ||
229 | { | ||
230 | static unsigned long dsa NOCACHEBSS_ATTR; | ||
231 | unsigned long addr; | ||
232 | long offs, size; | ||
233 | int oldstatus; | ||
234 | |||
235 | /* read burst dma source address register in channel context */ | ||
236 | sdma_read_words(&dsa, CHANNEL_CONTEXT_ADDR(DMA_PLAY_CH_NUM)+0x0b, 1); | ||
237 | |||
238 | oldstatus = disable_irq_save(); | ||
239 | addr = dsa; | ||
240 | offs = addr - (unsigned long)dma_play_bd.buf_addr; | ||
241 | size = dma_play_bd.mode.count; | ||
242 | restore_irq(oldstatus); | ||
243 | |||
244 | /* Be addresses are coherent (no buffer change during read) */ | ||
245 | if (offs >= 0 && offs < size) | ||
246 | { | ||
247 | *count = (size - offs) >> 2; | ||
248 | return (void *)((addr + 2) & ~3); | ||
249 | } | ||
250 | |||
251 | *count = 0; | ||
252 | return NULL; | ||
253 | } | ||
254 | |||
255 | void * pcm_dma_addr(void *addr) | 227 | void * pcm_dma_addr(void *addr) |
256 | { | 228 | { |
257 | return (void *)addr_virt_to_phys((unsigned long)addr); | 229 | return (void *)addr_virt_to_phys((unsigned long)addr); |