<!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 (2011-06-16)</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>2011-06-16 Joel Sherrill <joel.sherrill@oarcorp.com>

        PR 1818/misc
        * libmisc/cpuuse/cpuusagereport.c: Add SMP support to CPU Usage
        Reporting.
</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.2852&r2=text&tr2=1.2853&diff_format=h">M</a></td><td width='1%'>1.2853</td><td width='100%'>cpukit/ChangeLog</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/cpukit/libmisc/cpuuse/cpuusagereport.c.diff?r1=text&tr1=1.21&r2=text&tr2=1.22&diff_format=h">M</a></td><td width='1%'>1.22</td><td width='100%'>cpukit/libmisc/cpuuse/cpuusagereport.c</td></tr>
</table>
<pre>
<font color='#006600'>diff -u rtems/cpukit/ChangeLog:1.2852 rtems/cpukit/ChangeLog:1.2853
--- rtems/cpukit/ChangeLog:1.2852       Thu Jun 16 09:35:03 2011
+++ rtems/cpukit/ChangeLog      Thu Jun 16 11:24:05 2011
</font><font color='#997700'>@@ -1,3 +1,9 @@
</font><font color='#000088'>+2011-06-16    Joel Sherrill <joel.sherrill@oarcorp.com>
+
+       PR 1818/misc
+       * libmisc/cpuuse/cpuusagereport.c: Add SMP support to CPU Usage
+       Reporting.
+
</font> 2011-06-16        Jennifer Averett <Jennifer Averett@OARcorp.com
 
        * score/src/smp.c: Spinlock Name change necessary to resolve

<font color='#006600'>diff -u rtems/cpukit/libmisc/cpuuse/cpuusagereport.c:1.21 rtems/cpukit/libmisc/cpuuse/cpuusagereport.c:1.22
--- rtems/cpukit/libmisc/cpuuse/cpuusagereport.c:1.21   Tue Mar 15 14:03:38 2011
+++ rtems/cpukit/libmisc/cpuuse/cpuusagereport.c        Thu Jun 16 11:24:05 2011
</font><font color='#997700'>@@ -36,11 +36,34 @@
</font>   extern uint32_t           CPU_usage_Ticks_at_last_reset;
 #endif
 
<font color='#880000'>-/*PAGE
- *
</font><font color='#000088'>+#ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__
+  static bool is_executing_on_a_core(
+    Thread_Control    *the_thread,
+    Timestamp_Control *time_of_context_switch
+  )
+  {
+    #ifndef RTEMS_SMP
+      if ( _Thread_Executing->Object.id == the_thread->Object.id ) {
+        *time_of_context_switch = _Thread_Time_of_last_context_switch;
+        return true;
+      }
+    #else
+      int  cpu;
+      for ( cpu=0 ; cpu < _SMP_Processor_count ; cpu++ ) {
+        Per_CPU_Control *p = &_Per_CPU_Information[cpu];
+        if ( p->executing->Object.id == the_thread->Object.id ) {
+          *time_of_context_switch = p->time_of_last_context_switch;
+          return true;
+        }
+      }
+    #endif
+    return false;
+  }
+#endif
+
+/*
</font>  *  rtems_cpu_usage_report
  */
<font color='#880000'>-
</font> void rtems_cpu_usage_report_with_plugin(
   void                  *context,
   rtems_printk_plugin_t  print
<font color='#997700'>@@ -125,14 +148,16 @@
</font>         );
 
         #ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__
<font color='#000088'>+        {
+          Timestamp_Control last;
+
</font>           /*
            * If this is the currently executing thread, account for time
            * since the last context switch.
            */
           ran = the_thread->cpu_time_used;
<font color='#880000'>-          if ( _Thread_Executing->Object.id == the_thread->Object.id ) {
</font><font color='#000088'>+          if ( is_executing_on_a_core( the_thread, &last ) ) {
</font>             Timestamp_Control used;
<font color='#880000'>-            Timestamp_Control last = _Thread_Time_of_last_context_switch;
</font>             _TOD_Get_uptime( &uptime );
             _Timestamp_Subtract( &last, &uptime, &used );
             _Timestamp_Add_to( &ran, &used );
<font color='#997700'>@@ -153,6 +178,7 @@
</font>                TOD_NANOSECONDS_PER_MICROSECOND,
             ival, fval
           );
<font color='#000088'>+        }
</font>         #else
          if (total_units) {
             uint64_t ival_64;
</pre>
<p> </p>
<a name='cs2'></a>
<table border='0' cellspacing='0' cellpadding='5' width='100%' bgcolor='#eeeeee'>
<tr><td colspan='3' bgcolor='#dddddd'>
 <font color='#bb2222'><strong>ralf</strong></font>
</td></tr>
<tr><td colspan='3' bgcolor='#dddddd'><pre>2011-06-16 Ralf Corsépius <ralf.corsepius@rtems.org>

        * startup/bspdelay.c: Fix broken CVS-Id.
</pre></td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/c/src/lib/libbsp/sparc/erc32/ChangeLog.diff?r1=text&tr1=1.167&r2=text&tr2=1.168&diff_format=h">M</a></td><td width='1%'>1.168</td><td width='100%'>c/src/lib/libbsp/sparc/erc32/ChangeLog</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/c/src/lib/libbsp/sparc/erc32/startup/bspdelay.c.diff?r1=text&tr1=1.1&r2=text&tr2=1.2&diff_format=h">M</a></td><td width='1%'>1.2</td><td width='100%'>c/src/lib/libbsp/sparc/erc32/startup/bspdelay.c</td></tr>
</table>
<pre>
<font color='#006600'>diff -u rtems/c/src/lib/libbsp/sparc/erc32/ChangeLog:1.167 rtems/c/src/lib/libbsp/sparc/erc32/ChangeLog:1.168
--- rtems/c/src/lib/libbsp/sparc/erc32/ChangeLog:1.167  Sat Jun 11 12:24:13 2011
+++ rtems/c/src/lib/libbsp/sparc/erc32/ChangeLog        Thu Jun 16 11:31:48 2011
</font><font color='#997700'>@@ -1,3 +1,7 @@
</font><font color='#000088'>+2011-06-16    Ralf Corsépius <ralf.corsepius@rtems.org>
+
+       * startup/bspdelay.c: Fix broken CVS-Id.
+
</font> 2011-06-11        Joel Sherrill <joel.sherrill@oarcorp.com>
 
        * Makefile.am, configure.ac: runtest for this BSP obsoleted by

<font color='#006600'>diff -u rtems/c/src/lib/libbsp/sparc/erc32/startup/bspdelay.c:1.1 rtems/c/src/lib/libbsp/sparc/erc32/startup/bspdelay.c:1.2
--- rtems/c/src/lib/libbsp/sparc/erc32/startup/bspdelay.c:1.1   Mon May 23 12:41:30 2011
+++ rtems/c/src/lib/libbsp/sparc/erc32/startup/bspdelay.c       Thu Jun 16 11:31:48 2011
</font><font color='#997700'>@@ -8,7 +8,7 @@
</font>  *  found in the file LICENSE in this distribution or at
  *  http://www.rtems.com/license/LICENSE.
  *
<font color='#880000'>- *  $Id
</font><font color='#000088'>+ *  $Id$
</font>  */
 
 #include <bsp.h>
</pre>
<p> </p>
<a name='cs3'></a>
<table border='0' cellspacing='0' cellpadding='5' width='100%' bgcolor='#eeeeee'>
<tr><td colspan='3' bgcolor='#dddddd'>
 <font color='#bb2222'><strong>ralf</strong></font>
</td></tr>
<tr><td colspan='3' bgcolor='#dddddd'><pre>2011-06-16 Ralf Corsépius <ralf.corsepius@rtems.org>

        * Makefile.am: Don't generate host.cfg.in.
</pre></td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/c/src/make/ChangeLog.diff?r1=text&tr1=1.82&r2=text&tr2=1.83&diff_format=h">M</a></td><td width='1%'>1.83</td><td width='100%'>c/src/make/ChangeLog</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/c/src/make/Makefile.am.diff?r1=text&tr1=1.25&r2=text&tr2=1.26&diff_format=h">M</a></td><td width='1%'>1.26</td><td width='100%'>c/src/make/Makefile.am</td></tr>
</table>
<pre>
<font color='#006600'>diff -u rtems/c/src/make/ChangeLog:1.82 rtems/c/src/make/ChangeLog:1.83
--- rtems/c/src/make/ChangeLog:1.82     Fri Apr  1 13:12:07 2011
+++ rtems/c/src/make/ChangeLog  Thu Jun 16 11:49:22 2011
</font><font color='#997700'>@@ -1,3 +1,7 @@
</font><font color='#000088'>+2011-06-16    Ralf Corsépius <ralf.corsepius@rtems.org>
+
+       * Makefile.am: Don't generate host.cfg.in.
+
</font> 2011-04-01        Joel Sherrill <joel.sherrill@oarcorp.com>
 
        * Makefile.am, Makefile.inc.in, configure.ac, target.cfg.in: Update to

<font color='#006600'>diff -u rtems/c/src/make/Makefile.am:1.25 rtems/c/src/make/Makefile.am:1.26
--- rtems/c/src/make/Makefile.am:1.25   Fri Apr  1 13:12:07 2011
+++ rtems/c/src/make/Makefile.am        Thu Jun 16 11:49:22 2011
</font><font color='#997700'>@@ -24,11 +24,6 @@
</font> rtems_bsp_makedir = $(rtems_bspdir)/make
 rtems_bsp_make_DATA = bsp.cfg target.cfg
 
<font color='#880000'>-if MAINTAINER_MODE
-$(srcdir)/host.cfg.in: $(top_srcdir)/@RTEMS_TOPdir@/make/host.cfg.in
-       cp $< $@
-endif
-
</font> bsp.cfg: bsp.cfg.in Makefile
        sed \
        -e "s|[@]HAS_MP[@]|$(HAS_MP)|" \
</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>