From 0eeb4c1d32aab0dbfd2a8f20aa326ae2d98ca1c6 Mon Sep 17 00:00:00 2001 From: Freddie Chopin Date: Sun, 29 Jan 2017 10:27:17 +0100 Subject: Unify names of all lock objects In preparation for the patch that would allow retargeting of locking routines, rename all lock objects to follow this pattern: "___[recursive_]mutex". Following locks were renamed: __dd_hash_lock -> __dd_hash_mutex __sfp_lock -> __sfp_recursive_mutex __sinit_lock -> __sinit_recursive_mutex __atexit_lock -> __atexit_recursive_mutex _arc4random_mutex -> __arc4random_mutex __env_lock_object -> __env_recursive_mutex __malloc_lock_object -> __malloc_recursive_mutex __atexit_mutex -> __at_quick_exit_mutex __tz_lock_object -> __tz_mutex --- newlib/libc/stdlib/__atexit.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'newlib/libc/stdlib/__atexit.c') diff --git a/newlib/libc/stdlib/__atexit.c b/newlib/libc/stdlib/__atexit.c index d07f6c122..0f4aeb8a9 100644 --- a/newlib/libc/stdlib/__atexit.c +++ b/newlib/libc/stdlib/__atexit.c @@ -48,7 +48,7 @@ const void * __atexit_dummy = &__call_exitprocs; #endif #ifndef __SINGLE_THREAD__ -extern _LOCK_RECURSIVE_T __atexit_lock; +extern _LOCK_RECURSIVE_T __atexit_recursive_mutex; #endif #ifdef _REENT_GLOBAL_ATEXIT @@ -74,7 +74,7 @@ _DEFUN (__register_exitproc, register struct _atexit *p; #ifndef __SINGLE_THREAD__ - __lock_acquire_recursive(__atexit_lock); + __lock_acquire_recursive(__atexit_recursive_mutex); #endif p = _GLOBAL_ATEXIT; @@ -91,7 +91,7 @@ _DEFUN (__register_exitproc, { #ifndef _ATEXIT_DYNAMIC_ALLOC #ifndef __SINGLE_THREAD__ - __lock_release_recursive(__atexit_lock); + __lock_release_recursive(__atexit_recursive_mutex); #endif return -1; #else @@ -100,7 +100,7 @@ _DEFUN (__register_exitproc, if (!malloc) { #ifndef __SINGLE_THREAD__ - __lock_release_recursive(__atexit_lock); + __lock_release_recursive(__atexit_recursive_mutex); #endif return -1; } @@ -109,7 +109,7 @@ _DEFUN (__register_exitproc, if (p == NULL) { #ifndef __SINGLE_THREAD__ - __lock_release_recursive(__atexit_lock); + __lock_release_recursive(__atexit_recursive_mutex); #endif return -1; } @@ -133,7 +133,7 @@ _DEFUN (__register_exitproc, { #ifndef _ATEXIT_DYNAMIC_ALLOC #ifndef __SINGLE_THREAD__ - __lock_release_recursive(__atexit_lock); + __lock_release_recursive(__atexit_recursive_mutex); #endif return -1; #else @@ -143,7 +143,7 @@ _DEFUN (__register_exitproc, if (args == NULL) { #ifndef __SINGLE_THREAD__ - __lock_release(__atexit_lock); + __lock_release(__atexit_recursive_mutex); #endif return -1; } @@ -163,7 +163,7 @@ _DEFUN (__register_exitproc, } p->_fns[p->_ind++] = fn; #ifndef __SINGLE_THREAD__ - __lock_release_recursive(__atexit_lock); + __lock_release_recursive(__atexit_recursive_mutex); #endif return 0; } -- cgit v1.2.3