X-Git-Url: https://notaz.gp2x.de/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=cpu%2Fdrc%2Fcmn.c;h=91bd7eddab428098bfce0d185559e1597cb80133;hb=c25d78eec11d2a22adbd0bc7d42a24e2d79e40e7;hp=3ec039be169075d85e3df983239a5b5bf3eb416b;hpb=2446536be520914616403876d7e49621ac6f4b95;p=picodrive.git diff --git a/cpu/drc/cmn.c b/cpu/drc/cmn.c index 3ec039b..91bd7ed 100644 --- a/cpu/drc/cmn.c +++ b/cpu/drc/cmn.c @@ -6,10 +6,8 @@ * See COPYING file in the top-level directory. */ #include -#ifdef __linux__ -#include -#endif +#include #include "cmn.h" u8 __attribute__((aligned(4096))) tcache[DRC_TCACHE_SIZE]; @@ -17,20 +15,9 @@ u8 __attribute__((aligned(4096))) tcache[DRC_TCACHE_SIZE]; void drc_cmn_init(void) { -#ifdef __linux__ - void *tmp; - - tmp = mmap(tcache, DRC_TCACHE_SIZE, PROT_READ|PROT_WRITE|PROT_EXEC, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0); - printf("mmap tcache: %p, asked %p\n", tmp, tcache); -#endif + plat_mem_set_exec(tcache, sizeof(tcache)); } void drc_cmn_cleanup(void) { -#ifdef __linux__ - int ret; - ret = munmap(tcache, DRC_TCACHE_SIZE); - printf("munmap tcache: %i\n", ret); -#endif } -