aboutsummaryrefslogtreecommitdiff
path: root/mesalib/src/mapi/u_execmem.c
diff options
context:
space:
mode:
Diffstat (limited to 'mesalib/src/mapi/u_execmem.c')
-rw-r--r--mesalib/src/mapi/u_execmem.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/mesalib/src/mapi/u_execmem.c b/mesalib/src/mapi/u_execmem.c
index 357365263..ac1cae093 100644
--- a/mesalib/src/mapi/u_execmem.c
+++ b/mesalib/src/mapi/u_execmem.c
@@ -39,7 +39,7 @@
#define EXEC_MAP_SIZE (4*1024)
-u_mutex_declare_static(exec_mutex);
+static mtx_t exec_mutex = _MTX_INITIALIZER_NP;
static unsigned int head = 0;
@@ -123,7 +123,7 @@ u_execmem_alloc(unsigned int size)
{
void *addr = NULL;
- u_mutex_lock(exec_mutex);
+ mtx_lock(&exec_mutex);
if (!init_map())
goto bail;
@@ -137,7 +137,7 @@ u_execmem_alloc(unsigned int size)
head += size;
bail:
- u_mutex_unlock(exec_mutex);
+ mtx_unlock(&exec_mutex);
return addr;
}