summaryrefslogtreecommitdiffstats
path: root/newlib/libc/stdlib/__atexit.c
diff options
context:
space:
mode:
authorFreddie Chopin <freddie.chopin@gmail.com>2017-01-29 10:27:17 +0100
committerJeff Johnston <jjohnstn@redhat.com>2017-02-06 16:55:09 -0500
commit0eeb4c1d32aab0dbfd2a8f20aa326ae2d98ca1c6 (patch)
tree169fb9fc713636bec44116ba64ca15d023401a92 /newlib/libc/stdlib/__atexit.c
parent4e46ff3e8198adc00bbf4b4455c760ff0c599f44 (diff)
downloadcygnal-0eeb4c1d32aab0dbfd2a8f20aa326ae2d98ca1c6.tar.gz
cygnal-0eeb4c1d32aab0dbfd2a8f20aa326ae2d98ca1c6.tar.bz2
cygnal-0eeb4c1d32aab0dbfd2a8f20aa326ae2d98ca1c6.zip
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: "__<name>_[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
Diffstat (limited to 'newlib/libc/stdlib/__atexit.c')
-rw-r--r--newlib/libc/stdlib/__atexit.c16
1 files changed, 8 insertions, 8 deletions
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;
}