Changeset bbe654af in rtems
- Timestamp:
- Apr 19, 2016, 4:18:52 AM (5 years ago)
- Branches:
- 5, master
- Children:
- 48b04fc3
- Parents:
- b8bdced1
- git-author:
- Sebastian Huber <sebastian.huber@…> (04/19/16 04:18:52)
- git-committer:
- Sebastian Huber <sebastian.huber@…> (04/21/16 05:29:39)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
cpukit/score/include/rtems/score/coremuteximpl.h
rb8bdced1 rbbe654af 112 112 { 113 113 _Thread_queue_Destroy( &the_mutex->Wait_queue ); 114 } 115 116 RTEMS_INLINE_ROUTINE void _CORE_mutex_Acquire_critical( 117 CORE_mutex_Control *the_mutex, 118 ISR_lock_Context *lock_context 119 ) 120 { 121 _Thread_queue_Acquire_critical( &the_mutex->Wait_queue, lock_context ); 122 } 123 124 RTEMS_INLINE_ROUTINE void _CORE_mutex_Release( 125 CORE_mutex_Control *the_mutex, 126 ISR_lock_Context *lock_context 127 ) 128 { 129 _Thread_queue_Release( &the_mutex->Wait_queue, lock_context ); 114 130 } 115 131 … … 246 262 ); 247 263 } 248 _ Thread_queue_Acquire_critical( &the_mutex->Wait_queue, lock_context );264 _CORE_mutex_Acquire_critical( the_mutex, lock_context ); 249 265 if ( _CORE_mutex_Seize_interrupt_trylock( the_mutex, executing, lock_context ) ) { 250 266 if ( !wait ) { 251 _ Thread_queue_Release( &the_mutex->Wait_queue, lock_context );267 _CORE_mutex_Release( the_mutex, lock_context ); 252 268 executing->Wait.return_code = 253 269 CORE_MUTEX_STATUS_UNSATISFIED_NOWAIT; … … 463 479 464 480 if ( !_CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) { 465 _ Thread_queue_Release( &the_mutex->Wait_queue, lock_context );481 _CORE_mutex_Release( the_mutex, lock_context ); 466 482 return 0; 467 483 } /* else must be CORE_MUTEX_DISCIPLINES_PRIORITY_CEILING … … 477 493 current = executing->current_priority; 478 494 if ( current == ceiling ) { 479 _ Thread_queue_Release( &the_mutex->Wait_queue, lock_context );495 _CORE_mutex_Release( the_mutex, lock_context ); 480 496 return 0; 481 497 } … … 485 501 486 502 cpu_self = _Thread_Dispatch_disable_critical( lock_context ); 487 _ Thread_queue_Release( &the_mutex->Wait_queue, lock_context );503 _CORE_mutex_Release( the_mutex, lock_context ); 488 504 _Thread_Raise_priority( executing, ceiling ); 489 505 _Thread_Dispatch_enable( cpu_self ); … … 495 511 the_mutex->nest_count = 0; /* undo locking above */ 496 512 executing->resource_count--; /* undo locking above */ 497 _ Thread_queue_Release( &the_mutex->Wait_queue, lock_context );513 _CORE_mutex_Release( the_mutex, lock_context ); 498 514 return 0; 499 515 } … … 511 527 case CORE_MUTEX_NESTING_ACQUIRES: 512 528 the_mutex->nest_count++; 513 _ Thread_queue_Release( &the_mutex->Wait_queue, lock_context );529 _CORE_mutex_Release( the_mutex, lock_context ); 514 530 return 0; 515 531 #if defined(RTEMS_POSIX_API) 516 532 case CORE_MUTEX_NESTING_IS_ERROR: 517 533 executing->Wait.return_code = CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED; 518 _ Thread_queue_Release( &the_mutex->Wait_queue, lock_context );534 _CORE_mutex_Release( the_mutex, lock_context ); 519 535 return 0; 520 536 #endif
Note: See TracChangeset
for help on using the changeset viewer.