summaryrefslogtreecommitdiff
path: root/apps/codecs/spc.c
diff options
context:
space:
mode:
authorMichael Sevakis <jethead71@rockbox.org>2009-02-11 12:55:51 +0000
committerMichael Sevakis <jethead71@rockbox.org>2009-02-11 12:55:51 +0000
commit21f0c9a2829415f52b64cbdf965b01525e78f17a (patch)
treeb5cb8021097722969f75784011c9f64f991c0c3d /apps/codecs/spc.c
parent4cd7597172d916db9fc99bde4c03b669366f852a (diff)
downloadrockbox-21f0c9a2829415f52b64cbdf965b01525e78f17a.tar.gz
rockbox-21f0c9a2829415f52b64cbdf965b01525e78f17a.zip
Make basic cache functions into calls, and get rid of CACHE_FUNCTION_WRAPPERS and CACHE_FUNCTIONS_AS_CALL macros. Rename flush/invalidate_icache to cpucache_flush/invalidate. They're inlined only if an implementation isn't provided by defining HAVE_CPUCACHE_FLUSH/INVALIDATE.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@19971 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/codecs/spc.c')
-rw-r--r--apps/codecs/spc.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/apps/codecs/spc.c b/apps/codecs/spc.c
index 5ac594431a..6ceb704c7c 100644
--- a/apps/codecs/spc.c
+++ b/apps/codecs/spc.c
@@ -302,7 +302,7 @@ static bool emu_thread_process_msg(struct sample_queue_chunk *chunk)
302 if (id == SPC_EMU_LOAD) 302 if (id == SPC_EMU_LOAD)
303 { 303 {
304 struct spc_load *ld = (struct spc_load *)chunk->data; 304 struct spc_load *ld = (struct spc_load *)chunk->data;
305 invalidate_icache(); 305 ci->cpucache_invalidate();
306 SPC_Init(&spc_emu); 306 SPC_Init(&spc_emu);
307 sample_queue.retval = SPC_load_spc(&spc_emu, ld->buf, ld->size); 307 sample_queue.retval = SPC_load_spc(&spc_emu, ld->buf, ld->size);
308 308
@@ -376,7 +376,7 @@ static bool spc_emu_start(void)
376static inline int load_spc_buffer(uint8_t *buf, size_t size) 376static inline int load_spc_buffer(uint8_t *buf, size_t size)
377{ 377{
378 struct spc_load ld = { buf, size }; 378 struct spc_load ld = { buf, size };
379 flush_icache(); 379 ci->cpucache_flush();
380 return emu_thread_send_msg(SPC_EMU_LOAD, (intptr_t)&ld); 380 return emu_thread_send_msg(SPC_EMU_LOAD, (intptr_t)&ld);
381} 381}
382 382
@@ -386,7 +386,7 @@ static inline void spc_emu_quit(void)
386 emu_thread_send_msg(SPC_EMU_QUIT, 0); 386 emu_thread_send_msg(SPC_EMU_QUIT, 0);
387 /* Wait for emu thread to be killed */ 387 /* Wait for emu thread to be killed */
388 ci->thread_wait(emu_thread_id); 388 ci->thread_wait(emu_thread_id);
389 invalidate_icache(); 389 ci->cpucache_invalidate();
390 } 390 }
391} 391}
392 392