From 0e1d11f3f0f02768ced350fcb53056c55f0c545b Mon Sep 17 00:00:00 2001 From: Sebastian Huber Date: Fri, 27 May 2016 13:26:53 +0200 Subject: score: Add _Thread_queue_Context_set_MP_callout() Add _Thread_queue_Context_set_MP_callout() to simplify _Thread_queue_Context_initialize(). This makes it possible to more easily add additional fields to Thread_queue_Context. --- cpukit/rtems/src/semrelease.c | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'cpukit/rtems/src/semrelease.c') diff --git a/cpukit/rtems/src/semrelease.c b/cpukit/rtems/src/semrelease.c index 007914c09a..10fe743480 100644 --- a/cpukit/rtems/src/semrelease.c +++ b/cpukit/rtems/src/semrelease.c @@ -32,11 +32,7 @@ rtems_status_code rtems_semaphore_release( rtems_id id ) rtems_attribute attribute_set; Status_Control status; - the_semaphore = _Semaphore_Get( - id, - &queue_context, - _Semaphore_Core_mutex_mp_support - ); + the_semaphore = _Semaphore_Get( id, &queue_context ); if ( the_semaphore == NULL ) { #if defined(RTEMS_MULTIPROCESSING) @@ -46,6 +42,11 @@ rtems_status_code rtems_semaphore_release( rtems_id id ) #endif } + _Thread_queue_Context_set_MP_callout( + &queue_context, + _Semaphore_Core_mutex_mp_support + ); + attribute_set = the_semaphore->attribute_set; #if defined(RTEMS_SMP) if ( _Attributes_Is_multiprocessor_resource_sharing( attribute_set ) ) { -- cgit v1.2.3