summaryrefslogtreecommitdiffstats
path: root/cpukit/rtems/src
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2020-09-24 09:05:36 +0200
committerSebastian Huber <sebastian.huber@embedded-brains.de>2020-09-28 06:19:52 +0200
commit24ea1cebeb5e64ba2371c8e740ebe3c81d565ca2 (patch)
tree38ea2436105a3eb2a66d46a0190c3b3768e2b683 /cpukit/rtems/src
parentscore: Add <rtems/score/coremsgbuffer.h> (diff)
downloadrtems-24ea1cebeb5e64ba2371c8e740ebe3c81d565ca2.tar.bz2
rtems: Remove Message_queue_Control::attribute_set
Add Message_queue_Control::is_global if RTEMS_MULTIPROCESSING is defined. This reduces the Message_queue_Control size in standard RTEMS configurations. Update #4007.
Diffstat (limited to 'cpukit/rtems/src')
-rw-r--r--cpukit/rtems/src/msgqcreate.c12
-rw-r--r--cpukit/rtems/src/msgqdelete.c2
2 files changed, 7 insertions, 7 deletions
diff --git a/cpukit/rtems/src/msgqcreate.c b/cpukit/rtems/src/msgqcreate.c
index 79b198199e..20787f00a6 100644
--- a/cpukit/rtems/src/msgqcreate.c
+++ b/cpukit/rtems/src/msgqcreate.c
@@ -53,11 +53,11 @@ rtems_status_code rtems_message_queue_create(
return RTEMS_INVALID_ADDRESS;
#if defined(RTEMS_MULTIPROCESSING)
- if ( !_System_state_Is_multiprocessing ) {
- attribute_set = _Attributes_Clear( attribute_set, RTEMS_GLOBAL );
+ if ( _System_state_Is_multiprocessing ) {
+ is_global = _Attributes_Is_global( attribute_set );
+ } else {
+ is_global = false;
}
-
- is_global = _Attributes_Is_global( attribute_set );
#endif
if ( count == 0 )
@@ -99,9 +99,9 @@ rtems_status_code rtems_message_queue_create(
_Objects_Allocator_unlock();
return RTEMS_TOO_MANY;
}
-#endif
- the_message_queue->attribute_set = attribute_set;
+ the_message_queue->is_global = is_global;
+#endif
if (_Attributes_Is_priority( attribute_set ) )
discipline = CORE_MESSAGE_QUEUE_DISCIPLINES_PRIORITY;
diff --git a/cpukit/rtems/src/msgqdelete.c b/cpukit/rtems/src/msgqdelete.c
index 791f96e676..e1d57addc9 100644
--- a/cpukit/rtems/src/msgqdelete.c
+++ b/cpukit/rtems/src/msgqdelete.c
@@ -60,7 +60,7 @@ rtems_status_code rtems_message_queue_delete(
);
#if defined(RTEMS_MULTIPROCESSING)
- if ( _Attributes_Is_global( the_message_queue->attribute_set ) ) {
+ if ( the_message_queue->is_global ) {
_Objects_MP_Close(
&_Message_queue_Information,
the_message_queue->Object.id