<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>change log for rtems (2010-07-26)</title>
</head>
<body text='#000000' bgcolor='#ffffff'>
<a name='cs1'></a>
<table border='0' cellspacing='0' cellpadding='5' width='100%' bgcolor='#eeeeee'>
<tr><td colspan='3' bgcolor='#dddddd'>
 <font color='#bb2222'><strong>joel</strong></font>
</td></tr>
<tr><td colspan='3' bgcolor='#dddddd'><pre>2010-07-26 Joel Sherrill <joel.sherrilL@OARcorp.com>

        * rtems/src/taskmode.c, score/inline/rtems/score/thread.inl: Rework a
        bit to eliminate unreachable path for task blocked while calling
        rtems_task_mode() on itself.
</pre></td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/cpukit/ChangeLog.diff?r1=text&tr1=1.2525&r2=text&tr2=1.2526&diff_format=h">M</a></td><td width='1%'>1.2526</td><td width='100%'>cpukit/ChangeLog</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/cpukit/rtems/src/taskmode.c.diff?r1=text&tr1=1.12&r2=text&tr2=1.13&diff_format=h">M</a></td><td width='1%'>1.13</td><td width='100%'>cpukit/rtems/src/taskmode.c</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/cpukit/score/inline/rtems/score/thread.inl.diff?r1=text&tr1=1.40&r2=text&tr2=1.41&diff_format=h">M</a></td><td width='1%'>1.41</td><td width='100%'>cpukit/score/inline/rtems/score/thread.inl</td></tr>
</table>
<pre>
<font color='#006600'>diff -u rtems/cpukit/ChangeLog:1.2525 rtems/cpukit/ChangeLog:1.2526
--- rtems/cpukit/ChangeLog:1.2525       Mon Jul 26 17:20:43 2010
+++ rtems/cpukit/ChangeLog      Mon Jul 26 20:48:46 2010
</font><font color='#997700'>@@ -1,3 +1,9 @@
</font><font color='#000088'>+2010-07-26    Joel Sherrill <joel.sherrilL@OARcorp.com>
+
+       * rtems/src/taskmode.c, score/inline/rtems/score/thread.inl: Rework a
+       bit to eliminate unreachable path for task blocked while calling
+       rtems_task_mode() on itself.
+
</font> 2010-07-26        Joel Sherrill <joel.sherrill@oarcorp.com>
 
        * sapi/include/confdefs.h: Spelling.

<font color='#006600'>diff -u rtems/cpukit/rtems/src/taskmode.c:1.12 rtems/cpukit/rtems/src/taskmode.c:1.13
--- rtems/cpukit/rtems/src/taskmode.c:1.12      Mon Jun 28 19:34:11 2010
+++ rtems/cpukit/rtems/src/taskmode.c   Mon Jul 26 20:48:46 2010
</font><font color='#997700'>@@ -1,8 +1,7 @@
</font> /*
<font color='#880000'>- *  RTEMS Task Manager
</font><font color='#000088'>+ *  RTEMS Task Manager - Change Task Mode
</font>  *
<font color='#880000'>- *
- *  COPYRIGHT (c) 1989-1999.
</font><font color='#000088'>+ *  COPYRIGHT (c) 1989-2010.
</font>  *  On-Line Applications Research Corporation (OAR).
  *
  *  The license and distribution terms for this file may be
<font color='#997700'>@@ -32,8 +31,7 @@
</font> #include <rtems/score/apiext.h>
 #include <rtems/score/sysstate.h>
 
<font color='#880000'>-/*PAGE
- *
</font><font color='#000088'>+/*
</font>  *  rtems_task_mode
  *
  *  This directive enables and disables several modes of
<font color='#997700'>@@ -84,7 +82,6 @@
</font>   /*
    *  These are generic thread scheduling characteristics.
    */
<font color='#880000'>-
</font>   if ( mask & RTEMS_PREEMPT_MASK )
     executing->is_preemptible = _Modes_Is_preempt(mode_set) ? true : false;
 
<font color='#997700'>@@ -99,14 +96,12 @@
</font>   /*
    *  Set the new interrupt level
    */
<font color='#880000'>-
</font>   if ( mask & RTEMS_INTERRUPT_MASK )
     _Modes_Set_interrupt_level( mode_set );
 
   /*
    *  This is specific to the RTEMS API
    */
<font color='#880000'>-
</font>   is_asr_enabled = false;
   needs_asr_dispatching = false;
 
<font color='#997700'>@@ -121,9 +116,10 @@
</font>     }
   }
 
<font color='#880000'>-  if ( _System_state_Is_up( _System_state_Get() ) )
-    if ( _Thread_Evaluate_mode() || needs_asr_dispatching )
</font><font color='#000088'>+  if ( _System_state_Is_up( _System_state_Get() ) ) {
+     if (_Thread_Evaluate_is_dispatch_needed( needs_asr_dispatching ) )
</font>       _Thread_Dispatch();
<font color='#000088'>+  }
</font> 
   return RTEMS_SUCCESSFUL;
 }

<font color='#006600'>diff -u rtems/cpukit/score/inline/rtems/score/thread.inl:1.40 rtems/cpukit/score/inline/rtems/score/thread.inl:1.41
--- rtems/cpukit/score/inline/rtems/score/thread.inl:1.40       Thu Jun 24 17:40:32 2010
+++ rtems/cpukit/score/inline/rtems/score/thread.inl    Mon Jul 26 20:48:46 2010
</font><font color='#997700'>@@ -337,15 +337,20 @@
</font>  *  system and determines if a context switch is required.  This
  *  is usually called after changing an execution mode such as preemptability
  *  for a thread.
<font color='#000088'>+ *
+ *  @param[in] are_signals_pending specifies whether or not the API
+ *             level signals are pending and a dispatch is needed.
</font>  */
<font color='#880000'>-RTEMS_INLINE_ROUTINE bool _Thread_Evaluate_mode( void )
</font><font color='#000088'>+RTEMS_INLINE_ROUTINE bool _Thread_Evaluate_is_dispatch_needed(
+  bool are_signals_pending
+)
</font> {
   Thread_Control     *executing;
 
   executing = _Thread_Executing;
 
<font color='#880000'>-  if ( !_States_Is_ready( executing->current_state ) ||
-       ( !_Thread_Is_heir( executing ) && executing->is_preemptible ) ) {
</font><font color='#000088'>+  if ( are_signals_pending ||
+       (!_Thread_Is_heir( executing ) && executing->is_preemptible) ) {
</font>     _Context_Switch_necessary = true;
     return true;
   }
</pre>
<p> </p>

<p>--<br />
<small>Generated by <a href="http://www.codewiz.org/projects/index.html#loginfo">Deluxe Loginfo</a> 2.122 by Bernardo Innocenti <bernie@develer.com></small></p>
</body>
</html>