summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRalf Corsepius <ralf.corsepius@rtems.org>2005-01-13 08:25:52 +0000
committerRalf Corsepius <ralf.corsepius@rtems.org>2005-01-13 08:25:52 +0000
commitf49a82f3de1025e27d93a9aff27198ae6966f451 (patch)
tree62c665e87e53354694b28e67a5f6d05af545dcc5
parent83774d7ec43bb24a5ce09c94fd28b0555f5d5f17 (diff)
downloadrtems-f49a82f3de1025e27d93a9aff27198ae6966f451.tar.bz2
2005-01-13 Joel Sherrill <joel@oarcorp.com>
Ralf Corsepius <ralf.corsepius@rtems.org> * libcsupport/src/gxx_wrapper.c: Reflect GCC-4.0's gthr-rtems.h.
-rw-r--r--cpukit/ChangeLog5
-rw-r--r--cpukit/libcsupport/src/gxx_wrappers.c29
2 files changed, 33 insertions, 1 deletions
diff --git a/cpukit/ChangeLog b/cpukit/ChangeLog
index db62443479..1f32b62568 100644
--- a/cpukit/ChangeLog
+++ b/cpukit/ChangeLog
@@ -1,3 +1,8 @@
+2005-01-13 Joel Sherrill <joel@oarcorp.com>
+ Ralf Corsepius <ralf.corsepius@rtems.org>
+
+ * libcsupport/src/gxx_wrapper.c: Reflect GCC-4.0's gthr-rtems.h.
+
2005-01-09 Joel Sherrill <joel@oarcorp.com>
* librpc/include/rpc/clnt.h, librpc/src/rpc/authunix_prot.c,
diff --git a/cpukit/libcsupport/src/gxx_wrappers.c b/cpukit/libcsupport/src/gxx_wrappers.c
index d500f3fb5e..2549e68e6d 100644
--- a/cpukit/libcsupport/src/gxx_wrappers.c
+++ b/cpukit/libcsupport/src/gxx_wrappers.c
@@ -16,6 +16,11 @@
*
*/
+/*
+ * This file is only used if using gcc
+ */
+#if defined(__GNUC__)
+
#if HAVE_CONFIG_H
#include "config.h"
#endif
@@ -39,7 +44,7 @@
typedef void *__gthread_key_t;
typedef int __gthread_once_t;
typedef void *__gthread_mutex_t;
-
+typedef void *__gthread_recursive_mutex_t;
/* uncomment this if you need to debug this interface */
@@ -215,3 +220,25 @@ int rtems_gxx_mutex_unlock (__gthread_mutex_t *mutex)
#endif
return (rtems_semaphore_release( (rtems_id)*mutex ) == RTEMS_SUCCESSFUL) ? 0 :-1;
}
+
+void rtems_gxx_recursive_mutex_init_function(__gthread_recursive_mutex_t *mutex)
+{
+ rtems_gxx_mutex_init(mutex);
+}
+
+int rtems_gxx_recursive_mutex_lock(__gthread_recursive_mutex_t *mutex)
+{
+ return rtems_gxx_mutex_lock(mutex);
+}
+
+int rtems_gxx_recursive_mutex_trylock(__gthread_recursive_mutex_t *mutex)
+{
+ return rtems_gxx_mutex_trylock(mutex);
+}
+
+int rtems_gxx_recursive_mutex_unlock(__gthread_recursive_mutex_t *mutex)
+{
+ return rtems_gxx_mutex_unlock(mutex);
+}
+
+#endif /* __GNUC__ */