codecs_crt0.c needs to call cpucache_invalidate after copying code around.

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@28052 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
Thomas Martitz 2010-09-09 14:28:58 +00:00
parent 28b30d4772
commit 6af762f2bf
3 changed files with 6 additions and 10 deletions

View file

@ -118,10 +118,8 @@ struct codec_api ci = {
semaphore_release, semaphore_release,
#endif #endif
#if NUM_CORES > 1
cpucache_flush, cpucache_flush,
cpucache_invalidate, cpucache_invalidate,
#endif
/* strings and memory */ /* strings and memory */
strcpy, strcpy,

View file

@ -78,12 +78,12 @@
#define CODEC_ENC_MAGIC 0x52454E43 /* RENC */ #define CODEC_ENC_MAGIC 0x52454E43 /* RENC */
/* increase this every time the api struct changes */ /* increase this every time the api struct changes */
#define CODEC_API_VERSION 34 #define CODEC_API_VERSION 35
/* update this to latest version if a change to the api struct breaks /* update this to latest version if a change to the api struct breaks
backwards compatibility (and please take the opportunity to sort in any backwards compatibility (and please take the opportunity to sort in any
new function which are "waiting" at the end of the function table) */ new function which are "waiting" at the end of the function table) */
#define CODEC_MIN_API_VERSION 34 #define CODEC_MIN_API_VERSION 35
/* codec return codes */ /* codec return codes */
enum codec_status { enum codec_status {
@ -176,10 +176,8 @@ struct codec_api {
void (*semaphore_release)(struct semaphore *s); void (*semaphore_release)(struct semaphore *s);
#endif /* NUM_CORES */ #endif /* NUM_CORES */
#if NUM_CORES > 1
void (*cpucache_flush)(void); void (*cpucache_flush)(void);
void (*cpucache_invalidate)(void); void (*cpucache_invalidate)(void);
#endif
/* strings and memory */ /* strings and memory */
char* (*strcpy)(char *dst, const char *src); char* (*strcpy)(char *dst, const char *src);

View file

@ -47,10 +47,10 @@ enum codec_status codec_start(void)
#endif #endif
ci->memset(plugin_bss_start, 0, plugin_end_addr - plugin_bss_start); ci->memset(plugin_bss_start, 0, plugin_end_addr - plugin_bss_start);
#endif #endif
#if NUM_CORES > 1 /* writeback cleared iedata and bss areas, invalidate icache for
/* writeback cleared iedata and bss areas */ * copied code */
ci->cpucache_flush(); ci->cpucache_invalidate();
#endif
return codec_main(); return codec_main();
} }