diff options
Diffstat (limited to 'apps/plugin.h')
-rw-r--r-- | apps/plugin.h | 25 |
1 files changed, 24 insertions, 1 deletions
diff --git a/apps/plugin.h b/apps/plugin.h index a2e24f88d9..5f868e5654 100644 --- a/apps/plugin.h +++ b/apps/plugin.h | |||
@@ -112,7 +112,7 @@ | |||
112 | #define PLUGIN_MAGIC 0x526F634B /* RocK */ | 112 | #define PLUGIN_MAGIC 0x526F634B /* RocK */ |
113 | 113 | ||
114 | /* increase this every time the api struct changes */ | 114 | /* increase this every time the api struct changes */ |
115 | #define PLUGIN_API_VERSION 77 | 115 | #define PLUGIN_API_VERSION 78 |
116 | 116 | ||
117 | /* update this to latest version if a change to the api struct breaks | 117 | /* update this to latest version if a change to the api struct breaks |
118 | backwards compatibility (and please take the opportunity to sort in any | 118 | backwards compatibility (and please take the opportunity to sort in any |
@@ -627,6 +627,11 @@ struct plugin_api { | |||
627 | #if defined(TOSHIBA_GIGABEAT_F) || defined(SANSA_E200) | 627 | #if defined(TOSHIBA_GIGABEAT_F) || defined(SANSA_E200) |
628 | void (*lcd_yuv_set_options)(unsigned options); | 628 | void (*lcd_yuv_set_options)(unsigned options); |
629 | #endif | 629 | #endif |
630 | |||
631 | #ifdef CACHE_FUNCTIONS_AS_CALL | ||
632 | void (*flush_icache)(void); | ||
633 | void (*invalidate_icache)(void); | ||
634 | #endif | ||
630 | }; | 635 | }; |
631 | 636 | ||
632 | /* plugin header */ | 637 | /* plugin header */ |
@@ -710,4 +715,22 @@ enum plugin_status plugin_start(struct plugin_api* rockbox, void* parameter) | |||
710 | return (api)->memcmp(s1, s2, n); \ | 715 | return (api)->memcmp(s1, s2, n); \ |
711 | } | 716 | } |
712 | 717 | ||
718 | #ifndef CACHE_FUNCTION_WRAPPERS | ||
719 | |||
720 | #ifdef CACHE_FUNCTIONS_AS_CALL | ||
721 | #define CACHE_FUNCTION_WRAPPERS(api) \ | ||
722 | void flush_icache(void) \ | ||
723 | { \ | ||
724 | (api)->flush_icache(); \ | ||
725 | } \ | ||
726 | void invalidate_icache(void) \ | ||
727 | { \ | ||
728 | (api)->invalidate_icache(); \ | ||
729 | } | ||
730 | #else | ||
731 | #define CACHE_FUNCTION_WRAPPERS(api) | ||
732 | #endif /* CACHE_FUNCTIONS_AS_CALL */ | ||
733 | |||
734 | #endif /* CACHE_FUNCTION_WRAPPERS */ | ||
735 | |||
713 | #endif | 736 | #endif |