[rtems commit] smptests/smpthreadlife01: Avoid bad profiling stat

Sebastian Huber sebh at rtems.org
Tue Apr 1 12:03:56 UTC 2014


Module:    rtems
Branch:    master
Commit:    57db5f13fb10e1f0231f2a5ce084cd72726ff096
Changeset: http://git.rtems.org/rtems/commit/?id=57db5f13fb10e1f0231f2a5ce084cd72726ff096

Author:    Sebastian Huber <sebastian.huber at embedded-brains.de>
Date:      Tue Apr  1 08:40:23 2014 +0200

smptests/smpthreadlife01: Avoid bad profiling stat

---

 testsuites/smptests/smpthreadlife01/init.c |    6 +++++-
 1 files changed, 5 insertions(+), 1 deletions(-)

diff --git a/testsuites/smptests/smpthreadlife01/init.c b/testsuites/smptests/smpthreadlife01/init.c
index d1786e3..8ff5ea1 100644
--- a/testsuites/smptests/smpthreadlife01/init.c
+++ b/testsuites/smptests/smpthreadlife01/init.c
@@ -21,6 +21,7 @@
 #include <rtems.h>
 #include <rtems/counter.h>
 #include <rtems/libcsupport.h>
+#include <rtems/score/profiling.h>
 #include <rtems/score/smpbarrier.h>
 #include <rtems/score/threadimpl.h>
 
@@ -75,6 +76,9 @@ static void switch_extension(Thread_Control *executing, Thread_Control *heir)
     ctx->delay_switch_for_executing = NULL;
     _SMP_barrier_Wait(&ctx->barrier, &ctx->worker_barrier_state, CPU_COUNT);
     rtems_counter_delay_nanoseconds(100000000);
+
+    /* Avoid bad profiling statisitics */
+    _Profiling_Thread_dispatch_disable( _Per_CPU_Get(), 0 );
   }
 }
 
@@ -305,7 +309,7 @@ static void Init(rtems_task_argument arg)
   rtems_test_exit(0);
 }
 
-#define CONFIGURE_APPLICATION_NEEDS_CLOCK_DRIVER
+#define CONFIGURE_APPLICATION_DOES_NOT_NEED_CLOCK_DRIVER
 #define CONFIGURE_APPLICATION_NEEDS_CONSOLE_DRIVER
 
 #define CONFIGURE_SMP_APPLICATION




More information about the vc mailing list