diff options
Diffstat (limited to 'libpixelflinger/codeflinger/CodeCache.cpp')
-rw-r--r-- | libpixelflinger/codeflinger/CodeCache.cpp | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/libpixelflinger/codeflinger/CodeCache.cpp b/libpixelflinger/codeflinger/CodeCache.cpp index a713feb..4f2ede3 100644 --- a/libpixelflinger/codeflinger/CodeCache.cpp +++ b/libpixelflinger/codeflinger/CodeCache.cpp @@ -36,6 +36,12 @@ namespace android { #include <errno.h> #endif +#if defined(__mips__) +#include <asm/cachectl.h> +#include <errno.h> +#endif + +// ---------------------------------------------------------------------------- // ---------------------------------------------------------------------------- Assembly::Assembly(size_t size) @@ -155,12 +161,12 @@ int CodeCache::cache( const AssemblyKeyBase& keyBase, mCacheInUse += assemblySize; mWhen++; // synchronize caches... -#if defined(__arm__) +#if defined(__arm__) || defined(__mips__) const long base = long(assembly->base()); const long curr = base + long(assembly->size()); err = cacheflush(base, curr, 0); - ALOGE_IF(err, "__ARM_NR_cacheflush error %s\n", - strerror(errno)); + ALOGE_IF(err, "cacheflush error %s\n", + strerror(errno)); #endif } |