summaryrefslogtreecommitdiffstats
path: root/cpukit/score/inline
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2013-06-05 17:13:14 +0200
committerSebastian Huber <sebastian.huber@embedded-brains.de>2013-06-07 17:02:26 +0200
commit4f5baffd75f6310583f772b6bbfd852bbdf56b72 (patch)
tree0b8753f5a73dfe0705385b8245396d94b04294d9 /cpukit/score/inline
parentdcb4daf8e18eaaf2dbf9acfa42b1e54643519cf2 (diff)
downloadrtems-4f5baffd75f6310583f772b6bbfd852bbdf56b72.tar.bz2
score: Simplify _CORE_mutex_Seize_interrupt_try*
Diffstat (limited to 'cpukit/score/inline')
-rw-r--r--cpukit/score/inline/rtems/score/coremutex.inl14
1 files changed, 7 insertions, 7 deletions
diff --git a/cpukit/score/inline/rtems/score/coremutex.inl b/cpukit/score/inline/rtems/score/coremutex.inl
index f41a4de0b8..d34a967bd3 100644
--- a/cpukit/score/inline/rtems/score/coremutex.inl
+++ b/cpukit/score/inline/rtems/score/coremutex.inl
@@ -130,7 +130,7 @@ RTEMS_INLINE_ROUTINE bool _CORE_mutex_Is_priority_ceiling(
RTEMS_INLINE_ROUTINE int _CORE_mutex_Seize_interrupt_trylock_body(
CORE_mutex_Control *the_mutex,
- ISR_Level *level_p
+ ISR_Level level
)
{
Thread_Control *executing;
@@ -157,7 +157,7 @@ RTEMS_INLINE_ROUTINE int _CORE_mutex_Seize_interrupt_trylock_body(
}
if ( !_CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) {
- _ISR_Enable( *level_p );
+ _ISR_Enable( level );
return 0;
} /* else must be CORE_MUTEX_DISCIPLINES_PRIORITY_CEILING
*
@@ -171,13 +171,13 @@ RTEMS_INLINE_ROUTINE int _CORE_mutex_Seize_interrupt_trylock_body(
ceiling = the_mutex->Attributes.priority_ceiling;
current = executing->current_priority;
if ( current == ceiling ) {
- _ISR_Enable( *level_p );
+ _ISR_Enable( level );
return 0;
}
if ( current > ceiling ) {
_Thread_Disable_dispatch();
- _ISR_Enable( *level_p );
+ _ISR_Enable( level );
_Thread_Change_priority(
the_mutex->holder,
the_mutex->Attributes.priority_ceiling,
@@ -191,7 +191,7 @@ RTEMS_INLINE_ROUTINE int _CORE_mutex_Seize_interrupt_trylock_body(
the_mutex->lock = CORE_MUTEX_UNLOCKED;
the_mutex->nest_count = 0; /* undo locking above */
executing->resource_count--; /* undo locking above */
- _ISR_Enable( *level_p );
+ _ISR_Enable( level );
return 0;
}
}
@@ -207,12 +207,12 @@ RTEMS_INLINE_ROUTINE int _CORE_mutex_Seize_interrupt_trylock_body(
switch ( the_mutex->Attributes.lock_nesting_behavior ) {
case CORE_MUTEX_NESTING_ACQUIRES:
the_mutex->nest_count++;
- _ISR_Enable( *level_p );
+ _ISR_Enable( level );
return 0;
#if defined(RTEMS_POSIX_API)
case CORE_MUTEX_NESTING_IS_ERROR:
executing->Wait.return_code = CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED;
- _ISR_Enable( *level_p );
+ _ISR_Enable( level );
return 0;
#endif
case CORE_MUTEX_NESTING_BLOCKS: