diff options
author | Solomon Peachy <pizza@shaftnet.org> | 2020-11-11 23:20:19 -0500 |
---|---|---|
committer | Solomon Peachy <pizza@shaftnet.org> | 2020-11-12 15:59:09 +0000 |
commit | 388adff3cc4ab8584c2c99f9bc5ad7e309281d5e (patch) | |
tree | 8b05c374e6ace0ebf7c51641eff56e941de27df4 /firmware/pcm.c | |
parent | 1a68856f52f1b6dc89863758404e54c744fcf53a (diff) | |
download | rockbox-388adff3cc4ab8584c2c99f9bc5ad7e309281d5e.tar.gz rockbox-388adff3cc4ab8584c2c99f9bc5ad7e309281d5e.zip |
pcm: Further cleanup of unused bits of the PCM ACPI:
* pcm_get_bytes_remaining()
* pcm_calculate_peaks()
* pcm_get_peak_buffer()
Nothing in-tree uses these at all (except for the lua plugin wrapper)
Change-Id: I971b7beed6760250c8b1ce58f401a601e1e2d585
Diffstat (limited to 'firmware/pcm.c')
-rw-r--r-- | firmware/pcm.c | 29 |
1 files changed, 0 insertions, 29 deletions
diff --git a/firmware/pcm.c b/firmware/pcm.c index 7a7043bef8..6fc0b626f7 100644 --- a/firmware/pcm.c +++ b/firmware/pcm.c | |||
@@ -37,7 +37,6 @@ | |||
37 | * ==Playback== | 37 | * ==Playback== |
38 | * Public - | 38 | * Public - |
39 | * pcm_postinit | 39 | * pcm_postinit |
40 | * pcm_get_bytes_waiting | ||
41 | * pcm_play_lock | 40 | * pcm_play_lock |
42 | * pcm_play_unlock | 41 | * pcm_play_unlock |
43 | * Semi-private - | 42 | * Semi-private - |
@@ -47,7 +46,6 @@ | |||
47 | * pcm_play_dma_postinit | 46 | * pcm_play_dma_postinit |
48 | * pcm_play_dma_start | 47 | * pcm_play_dma_start |
49 | * pcm_play_dma_stop | 48 | * pcm_play_dma_stop |
50 | * pcm_play_dma_get_peak_buffer | ||
51 | * Data Read/Written within TSP - | 49 | * Data Read/Written within TSP - |
52 | * pcm_sampr (R) | 50 | * pcm_sampr (R) |
53 | * pcm_fsel (R) | 51 | * pcm_fsel (R) |
@@ -118,11 +116,6 @@ static inline void pcm_play_dma_stop_int(void) | |||
118 | pcm_play_dma_stop(); | 116 | pcm_play_dma_stop(); |
119 | } | 117 | } |
120 | 118 | ||
121 | static inline const void * pcm_play_dma_get_peak_buffer_int(int *count) | ||
122 | { | ||
123 | return pcm_play_dma_get_peak_buffer(count); | ||
124 | } | ||
125 | |||
126 | bool pcm_play_dma_complete_callback(enum pcm_dma_status status, | 119 | bool pcm_play_dma_complete_callback(enum pcm_dma_status status, |
127 | const void **addr, size_t *size) | 120 | const void **addr, size_t *size) |
128 | { | 121 | { |
@@ -244,28 +237,6 @@ void pcm_do_peak_calculation(struct pcm_peaks *peaks, bool active, | |||
244 | } | 237 | } |
245 | } | 238 | } |
246 | 239 | ||
247 | void pcm_calculate_peaks(int *left, int *right) | ||
248 | { | ||
249 | /* peak data for the global peak values - i.e. what the final output is */ | ||
250 | static struct pcm_peaks peaks; | ||
251 | |||
252 | int count; | ||
253 | const void *addr = pcm_play_dma_get_peak_buffer_int(&count); | ||
254 | |||
255 | pcm_do_peak_calculation(&peaks, pcm_playing, addr, count); | ||
256 | |||
257 | if (left) | ||
258 | *left = peaks.left; | ||
259 | |||
260 | if (right) | ||
261 | *right = peaks.right; | ||
262 | } | ||
263 | |||
264 | const void * pcm_get_peak_buffer(int *count) | ||
265 | { | ||
266 | return pcm_play_dma_get_peak_buffer_int(count); | ||
267 | } | ||
268 | |||
269 | bool pcm_is_playing(void) | 240 | bool pcm_is_playing(void) |
270 | { | 241 | { |
271 | return pcm_playing; | 242 | return pcm_playing; |