summaryrefslogtreecommitdiffstats
path: root/cpukit/score/include/rtems/score/threadqimpl.h
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2016-08-22 10:58:34 +0200
committerSebastian Huber <sebastian.huber@embedded-brains.de>2016-09-08 09:55:27 +0200
commite41308eab8ae4505844d8e499664424f8c7f2bd1 (patch)
tree7dffe5edacd3f245ba5ef3b64b431b7e4c74c454 /cpukit/score/include/rtems/score/threadqimpl.h
parentscore: Simplify thread queue acquire/release (diff)
downloadrtems-e41308eab8ae4505844d8e499664424f8c7f2bd1.tar.bz2
score: Introduce Thread_queue_Lock_context
Introduce Thread_queue_Lock_context to contain the context necessary for thread queue lock and thread wait lock acquire/release operations to reduce the Thread_Control size.
Diffstat (limited to 'cpukit/score/include/rtems/score/threadqimpl.h')
-rw-r--r--cpukit/score/include/rtems/score/threadqimpl.h12
1 files changed, 6 insertions, 6 deletions
diff --git a/cpukit/score/include/rtems/score/threadqimpl.h b/cpukit/score/include/rtems/score/threadqimpl.h
index 641c618b1d..977b0ceb38 100644
--- a/cpukit/score/include/rtems/score/threadqimpl.h
+++ b/cpukit/score/include/rtems/score/threadqimpl.h
@@ -372,7 +372,7 @@ RTEMS_INLINE_ROUTINE void _Thread_queue_Acquire_critical(
{
_Thread_queue_Do_acquire_critical(
the_thread_queue,
- &queue_context->Lock_context
+ &queue_context->Lock_context.Lock_context
);
}
@@ -381,7 +381,7 @@ RTEMS_INLINE_ROUTINE void _Thread_queue_Acquire(
Thread_queue_Context *queue_context
)
{
- _ISR_lock_ISR_disable( &queue_context->Lock_context );
+ _ISR_lock_ISR_disable( &queue_context->Lock_context.Lock_context );
_Thread_queue_Acquire_critical( the_thread_queue, queue_context );
}
@@ -422,7 +422,7 @@ RTEMS_INLINE_ROUTINE void _Thread_queue_Release_critical(
{
_Thread_queue_Do_release_critical(
the_thread_queue,
- &queue_context->Lock_context
+ &queue_context->Lock_context.Lock_context
);
}
@@ -432,7 +432,7 @@ RTEMS_INLINE_ROUTINE void _Thread_queue_Release(
)
{
_Thread_queue_Release_critical( the_thread_queue, queue_context );
- _ISR_lock_ISR_enable( &queue_context->Lock_context );
+ _ISR_lock_ISR_enable( &queue_context->Lock_context.Lock_context );
}
Thread_Control *_Thread_queue_Do_dequeue(
@@ -511,13 +511,13 @@ Thread_Control *_Thread_queue_Do_dequeue(
* Thread_Control *executing;
*
* _Thread_queue_Context_initialize( &queue_context );
- * _Thread_queue_Acquire( &mutex->Queue, &queue_context.Lock_context );
+ * _Thread_queue_Acquire( &mutex->Queue, queue_context );
*
* executing = _Thread_Executing;
*
* if ( mutex->owner == NULL ) {
* mutex->owner = executing;
- * _Thread_queue_Release( &mutex->Queue, &queue_context.Lock_context );
+ * _Thread_queue_Release( &mutex->Queue, queue_context );
* } else {
* _Thread_queue_Context_set_expected_level( &queue_context, 1 );
* _Thread_queue_Enqueue_critical(