[examples-v2 commit] posix_api/psx_sched_report/test.c: Uses default configuration now.

Joel Sherrill joel at rtems.org
Sun Aug 7 17:19:39 UTC 2016


Module:    examples-v2
Branch:    master
Commit:    108ea77f6990551aa91fa9b44e02d592480af0c1
Changeset: http://git.rtems.org/examples-v2/commit/?id=108ea77f6990551aa91fa9b44e02d592480af0c1

Author:    Joel Sherrill <joel at rtems.org>
Date:      Sun Aug  7 12:17:41 2016 -0500

posix_api/psx_sched_report/test.c: Uses default configuration now.

---

 posix_api/psx_sched_report/test.c | 35 ++++++-----------------------------
 1 file changed, 6 insertions(+), 29 deletions(-)

diff --git a/posix_api/psx_sched_report/test.c b/posix_api/psx_sched_report/test.c
index 8d0b9b3..f9cab61 100644
--- a/posix_api/psx_sched_report/test.c
+++ b/posix_api/psx_sched_report/test.c
@@ -1,5 +1,5 @@
 /*
- *  Simple test program -- simplified version of sample test hello.
+ *  Program to print POSIX Scheduler Characteristics
  */
 
 #include <stdlib.h>
@@ -30,39 +30,16 @@ void print_sched_info(
               (long)t.tv_sec, (long)t.tv_nsec );
 }
 
-
-#if defined(__rtems__)
-  #include <bsp.h>
-
-rtems_task Init(
-  rtems_task_argument ignored
-)
-#else
 int main()
-#endif
 {
   print_sched_info( "SCHED_OTHER", SCHED_OTHER );
   print_sched_info( "SCHED_FIFO", SCHED_FIFO );
   print_sched_info( "SCHED_RR", SCHED_RR );
+#if defined(SCHED_SPORADIC)
+  print_sched_info( "SCHED_SPORADIC", SCHED_RR );
+#else
+  printf( "SCHED_SPORADIC is not supported\n" );
+#endif
 
   exit( 0 );
 }
-
-#if defined(__rtems__)
-/* configuration information */
-
-/* NOTICE: the clock driver is explicitly disabled */
-#define CONFIGURE_APPLICATION_DOES_NOT_NEED_CLOCK_DRIVER
-#define CONFIGURE_APPLICATION_NEEDS_CONSOLE_DRIVER
-
-#define CONFIGURE_RTEMS_INIT_TASKS_TABLE
-#define CONFIGURE_MICROSECONDS_PER_TICK 1000
-#define CONFIGURE_TICKS_PER_TIMESLICE   1
-#define CONFIGURE_MAXIMUM_TASKS 1
-
-#define CONFIGURE_INIT
-
-#include <rtems/confdefs.h>
-#endif
-
-/* end of file */



More information about the vc mailing list