From 21f0c9a2829415f52b64cbdf965b01525e78f17a Mon Sep 17 00:00:00 2001 From: Michael Sevakis Date: Wed, 11 Feb 2009 12:55:51 +0000 Subject: 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 --- apps/plugin.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'apps/plugin.c') diff --git a/apps/plugin.c b/apps/plugin.c index 3b14b0032f..f9f1c53617 100644 --- a/apps/plugin.c +++ b/apps/plugin.c @@ -327,9 +327,9 @@ static const struct plugin_api rockbox_api = { trigger_cpu_boost, cancel_cpu_boost, #endif -#ifdef CACHE_FUNCTIONS_AS_CALL - flush_icache, - invalidate_icache, +#if NUM_CORES > 1 + cpucache_flush, + cpucache_invalidate, #endif timer_register, timer_unregister, @@ -694,7 +694,7 @@ int plugin_load(const char* plugin, const void* parameter) #if NUM_CORES > 1 /* Make sure COP cache is flushed and invalidated before loading */ my_core = switch_core(CURRENT_CORE ^ 1); - invalidate_icache(); + cpucache_invalidate(); switch_core(my_core); #endif @@ -742,7 +742,7 @@ int plugin_load(const char* plugin, const void* parameter) lcd_remote_update(); #endif - invalidate_icache(); + cpucache_invalidate(); oldbars = viewportmanager_set_statusbar(VP_SB_HIDE_ALL); rc = hdr->entry_point(parameter); @@ -854,7 +854,7 @@ void plugin_iram_init(char *iramstart, char *iramcopy, size_t iram_size, memset(iramcopy, 0, iram_size); #if NUM_CORES > 1 /* writeback cleared iedata and iramcopy areas */ - flush_icache(); + cpucache_flush(); #endif } #endif /* PLUGIN_USE_IRAM */ -- cgit v1.2.3