summaryrefslogtreecommitdiffstats
path: root/cpukit/score/include/rtems
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2017-09-27 15:08:33 +0200
committerSebastian Huber <sebastian.huber@embedded-brains.de>2017-10-05 14:29:02 +0200
commitde59c065c57cb8526662ee6da28a57ad16fdde66 (patch)
tree21f4a2adbd58f65f722051bca435572fbf5dcf05 /cpukit/score/include/rtems
parentposix: Implement self-contained POSIX condvar (diff)
downloadrtems-de59c065c57cb8526662ee6da28a57ad16fdde66.tar.bz2
posix: Implement self-contained POSIX mutex
POSIX mutexes are now available in all configurations and no longer depend on --enable-posix. Update #2514. Update #3112.
Diffstat (limited to 'cpukit/score/include/rtems')
-rw-r--r--cpukit/score/include/rtems/score/muteximpl.h37
-rw-r--r--cpukit/score/include/rtems/score/objectimpl.h1
-rw-r--r--cpukit/score/include/rtems/sysinit.h1
3 files changed, 37 insertions, 2 deletions
diff --git a/cpukit/score/include/rtems/score/muteximpl.h b/cpukit/score/include/rtems/score/muteximpl.h
new file mode 100644
index 0000000000..5fd4f5e8be
--- /dev/null
+++ b/cpukit/score/include/rtems/score/muteximpl.h
@@ -0,0 +1,37 @@
+/*
+ * Copyright (c) 2015, 2017 embedded brains GmbH. All rights reserved.
+ *
+ * embedded brains GmbH
+ * Dornierstr. 4
+ * 82178 Puchheim
+ * Germany
+ * <rtems@embedded-brains.de>
+ *
+ * The license and distribution terms for this file may be
+ * found in the file LICENSE in this distribution or at
+ * http://www.rtems.org/license/LICENSE.
+ */
+
+#ifndef _RTEMS_SCORE_MUTEXIMPL_H
+#define _RTEMS_SCORE_MUTEXIMPL_H
+
+#include <rtems/score/threadqimpl.h>
+
+#ifdef __cplusplus
+extern "C" {
+#endif /* __cplusplus */
+
+typedef struct {
+ Thread_queue_Syslock_queue Queue;
+} Mutex_Control;
+
+typedef struct {
+ Mutex_Control Mutex;
+ unsigned int nest_level;
+} Mutex_recursive_Control;
+
+#ifdef __cplusplus
+}
+#endif /* __cplusplus */
+
+#endif /* _RTEMS_SCORE_MUTEXIMPL_H */
diff --git a/cpukit/score/include/rtems/score/objectimpl.h b/cpukit/score/include/rtems/score/objectimpl.h
index 435e82cc45..0338a481ea 100644
--- a/cpukit/score/include/rtems/score/objectimpl.h
+++ b/cpukit/score/include/rtems/score/objectimpl.h
@@ -87,7 +87,6 @@ typedef enum {
OBJECTS_POSIX_KEYS = 2,
OBJECTS_POSIX_INTERRUPTS = 3,
OBJECTS_POSIX_MESSAGE_QUEUES = 5,
- OBJECTS_POSIX_MUTEXES = 6,
OBJECTS_POSIX_SEMAPHORES = 7,
OBJECTS_POSIX_TIMERS = 9,
OBJECTS_POSIX_SHMS = 12
diff --git a/cpukit/score/include/rtems/sysinit.h b/cpukit/score/include/rtems/sysinit.h
index 595629fd04..7ab3d0b631 100644
--- a/cpukit/score/include/rtems/sysinit.h
+++ b/cpukit/score/include/rtems/sysinit.h
@@ -47,7 +47,6 @@ extern "C" {
#define RTEMS_SYSINIT_CLASSIC_BARRIER 00034a
#define RTEMS_SYSINIT_POSIX_SIGNALS 000360
#define RTEMS_SYSINIT_POSIX_THREADS 000361
-#define RTEMS_SYSINIT_POSIX_MUTEX 000363
#define RTEMS_SYSINIT_POSIX_MESSAGE_QUEUE 000364
#define RTEMS_SYSINIT_POSIX_SEMAPHORE 000365
#define RTEMS_SYSINIT_POSIX_TIMER 000366