summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2013-01-02 18:56:37 +0100
committerSebastian Huber <sebastian.huber@embedded-brains.de>2013-01-07 15:14:07 +0100
commit1794f33a2f038d791d89a2a69ccca4855347bbe0 (patch)
tree5aa1b288c4c48084654ea2fd6a9aa987df8eb425
parentrtems: Simplify _Event_Surrender() (diff)
downloadrtems-1794f33a2f038d791d89a2a69ccca4855347bbe0.tar.bz2
rtems: Simplify _Event_Surrender()
Remove superfluous test for _ISR_Is_in_progress().
-rw-r--r--cpukit/rtems/src/eventsurrender.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/cpukit/rtems/src/eventsurrender.c b/cpukit/rtems/src/eventsurrender.c
index ce7edc7a8e..6e8dbbdbea 100644
--- a/cpukit/rtems/src/eventsurrender.c
+++ b/cpukit/rtems/src/eventsurrender.c
@@ -57,11 +57,13 @@ void _Event_Surrender(
}
/*
- * If we are in an ISR and sending to the current thread, then
- * we have a critical section issue to deal with.
+ * If we are sending to the executing thread, then we have a critical
+ * section issue to deal with. The entity sending to the executing thread
+ * can be either the executing thread or an ISR. In case it is the
+ * executing thread, then the blocking operation state is not equal to
+ * THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED.
*/
- if ( _ISR_Is_in_progress() &&
- _Thread_Is_executing( the_thread ) &&
+ if ( _Thread_Is_executing( the_thread ) &&
*sync_state == THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED ) {
if ( seized_events == event_condition || _Options_Is_any(option_set) ) {
event->pending_events = _Event_sets_Clear(