diff options
Diffstat (limited to 'testsuites/mptests')
-rw-r--r-- | testsuites/mptests/Makefile.am | 2 | ||||
-rw-r--r-- | testsuites/mptests/configure.ac | 3 | ||||
-rw-r--r-- | testsuites/mptests/mp02/Makefile.am | 4 | ||||
-rw-r--r-- | testsuites/mptests/mp02/init.c | 61 | ||||
-rw-r--r-- | testsuites/mptests/mp02/node1/Makefile.am | 22 | ||||
-rw-r--r-- | testsuites/mptests/mp02/node1/mp02-node1.doc | 43 | ||||
-rw-r--r-- | testsuites/mptests/mp02/node1/mp02-node1.scn | 14 | ||||
-rw-r--r-- | testsuites/mptests/mp02/node2/Makefile.am | 22 | ||||
-rw-r--r-- | testsuites/mptests/mp02/node2/mp02-node2.doc | 9 | ||||
-rw-r--r-- | testsuites/mptests/mp02/node2/mp02-node2.scn | 14 | ||||
-rw-r--r-- | testsuites/mptests/mp02/system.h | 46 | ||||
-rw-r--r-- | testsuites/mptests/mp02/task1.c | 113 |
12 files changed, 1 insertions, 352 deletions
diff --git a/testsuites/mptests/Makefile.am b/testsuites/mptests/Makefile.am index 4bc33df2b9..45889f1835 100644 --- a/testsuites/mptests/Makefile.am +++ b/testsuites/mptests/Makefile.am @@ -1,6 +1,6 @@ ACLOCAL_AMFLAGS = -I ../aclocal -_SUBDIRS = mp01 mp02 mp03 mp04 mp05 mp06 mp07 mp08 mp09 mp10 mp11 mp12 mp13 \ +_SUBDIRS = mp01 mp03 mp04 mp05 mp06 mp07 mp08 mp09 mp10 mp11 mp12 mp13 \ mp14 include $(top_srcdir)/../automake/test-subdirs.am diff --git a/testsuites/mptests/configure.ac b/testsuites/mptests/configure.ac index 282d97c552..f01cfc1c94 100644 --- a/testsuites/mptests/configure.ac +++ b/testsuites/mptests/configure.ac @@ -35,9 +35,6 @@ AC_CONFIG_FILES([Makefile mp01/Makefile mp01/node1/Makefile mp01/node2/Makefile -mp02/Makefile -mp02/node1/Makefile -mp02/node2/Makefile mp03/Makefile mp03/node1/Makefile mp03/node2/Makefile diff --git a/testsuites/mptests/mp02/Makefile.am b/testsuites/mptests/mp02/Makefile.am deleted file mode 100644 index 08a90da412..0000000000 --- a/testsuites/mptests/mp02/Makefile.am +++ /dev/null @@ -1,4 +0,0 @@ -SUBDIRS = node1 node2 - -include $(top_srcdir)/../automake/subdirs.am -include $(top_srcdir)/../automake/local.am diff --git a/testsuites/mptests/mp02/init.c b/testsuites/mptests/mp02/init.c deleted file mode 100644 index 7155e88f14..0000000000 --- a/testsuites/mptests/mp02/init.c +++ /dev/null @@ -1,61 +0,0 @@ -/* Init - * - * This routine is the initialization task for this test program. - * It is a user initialization task and has the responsibility for creating - * and starting the tasks that make up the test. If the time of day - * clock is required for the test, it should also be set to a known - * value by this function. - * - * Input parameters: - * argument - task argument - * - * Output parameters: NONE - * - * COPYRIGHT (c) 1989-1999. - * On-Line Applications Research Corporation (OAR). - * - * The license and distribution terms for this file may be - * found in the file LICENSE in this distribution or at - * http://www.rtems.org/license/LICENSE. - */ - -#ifdef HAVE_CONFIG_H -#include "config.h" -#endif - -#define CONFIGURE_INIT -#include "system.h" - -rtems_task Init( - rtems_task_argument argument -) -{ - rtems_status_code status; - - printf( - "\n\n*** TEST 2 -- NODE %" PRIu32 " ***\n", - Multiprocessing_configuration.node - ); - - Task_name[ 1 ] = rtems_build_name( '1', '1', '1', ' ' ); - Task_name[ 2 ] = rtems_build_name( '2', '2', '2', ' ' ); - - puts( "Creating Test_task (Global)" ); - status = rtems_task_create( - Task_name[Multiprocessing_configuration.node], - 1, - RTEMS_MINIMUM_STACK_SIZE, - RTEMS_NO_PREEMPT, - RTEMS_GLOBAL, - &Task_id[ 1 ] - ); - directive_failed( status, "rtems_task_create" ); - - puts( "Starting Test_task (Global)" ); - status = rtems_task_start( Task_id[ 1 ], Test_task, 0 ); - directive_failed( status, "rtems_task_start" ); - - puts( "Deleting initialization task" ); - status = rtems_task_delete( RTEMS_SELF ); - directive_failed( status, "rtems_task_delete of RTEMS_SELF" ); -} diff --git a/testsuites/mptests/mp02/node1/Makefile.am b/testsuites/mptests/mp02/node1/Makefile.am deleted file mode 100644 index f3ae2b4171..0000000000 --- a/testsuites/mptests/mp02/node1/Makefile.am +++ /dev/null @@ -1,22 +0,0 @@ -rtems_tests_PROGRAMS = mp02-node1 -mp02_node1_SOURCES = ../init.c ../task1.c ../system.h - -dist_rtems_tests_DATA = mp02-node1.scn -dist_rtems_tests_DATA += mp02-node1.doc - -include $(RTEMS_ROOT)/make/custom/@RTEMS_BSP@.cfg -include $(top_srcdir)/../automake/compile.am -include $(top_srcdir)/../automake/leaf.am - -AM_CPPFLAGS += -DNODE_NUMBER=1 -I$(srcdir)/.. - -AM_CPPFLAGS += -I$(top_srcdir)/../support/include - -LINK_OBJS = $(mp02_node1_OBJECTS) -LINK_LIBS = $(mp02_node1_LDLIBS) - -mp02-node1$(EXEEXT): $(mp02_node1_OBJECTS) $(mp02_node1_DEPENDENCIES) - @rm -f mp02-node1$(EXEEXT) - $(make-exe) - -include $(top_srcdir)/../automake/local.am diff --git a/testsuites/mptests/mp02/node1/mp02-node1.doc b/testsuites/mptests/mp02/node1/mp02-node1.doc deleted file mode 100644 index 53959a2f15..0000000000 --- a/testsuites/mptests/mp02/node1/mp02-node1.doc +++ /dev/null @@ -1,43 +0,0 @@ -# COPYRIGHT (c) 1989-1999. -# On-Line Applications Research Corporation (OAR). -# -# The license and distribution terms for this file may be -# found in the file LICENSE in this distribution or at -# http://www.rtems.org/license/LICENSE. -# - - -This file describes the directives and concepts tested by this test set. - -test set name: test51 - -directives: - ex_init, ex_start, t_create, t_start, tm_tick, i_return, t_ident, - tm_set, tm_get, tm_wkafter, t_delete, t_restart, t_getreg, t_setreg - -concepts: - - a. Verifies system can create and start both the executive's system - initialization and idle task. - - b. Verifies can print strings to the CRT on port 2 of the mvme136 board - using Print and Println in the board support package. - - c. Verifies interrupt handler can handler a task switch from an interrupt - as specified with the i_return directive. - - d. Verifies executive initialization performed correctly. - - e. Verifies that a task can get the task identification number of itself. - - f. Verifies that a task can get the task identification number - of another task. - - g. Verifies that a task can delete itself or another task. - - h. Verifies that errors are returned in the following situations: - 1) when attempting to delete a remote task. - 2) when attempting to start a remote task. - 3) when attempting to restart a remote task. - - i. Verifies that a remote task's registers can be set and read. diff --git a/testsuites/mptests/mp02/node1/mp02-node1.scn b/testsuites/mptests/mp02/node1/mp02-node1.scn deleted file mode 100644 index 72fdefe69d..0000000000 --- a/testsuites/mptests/mp02/node1/mp02-node1.scn +++ /dev/null @@ -1,14 +0,0 @@ -*** TEST 2 -- NODE 1 *** -Creating Test_task (Global) -Starting Test_task (Global) -Deleting initialization task -Remote task's name is : 222 -Getting TID of remote task (all nodes) -Getting TID of remote task (1 node) -rtems_task_delete of remote task returned the correct error -rtems_task_start of remote task returned the correct error -rtems_task_restart of remote task returned the correct error -Setting notepad 1 of the remote task to 1 -Getting a notepad of the remote task -Remote notepad set and read correctly -*** END OF TEST 2 *** diff --git a/testsuites/mptests/mp02/node2/Makefile.am b/testsuites/mptests/mp02/node2/Makefile.am deleted file mode 100644 index 107d845653..0000000000 --- a/testsuites/mptests/mp02/node2/Makefile.am +++ /dev/null @@ -1,22 +0,0 @@ -rtems_tests_PROGRAMS = mp02-node2 -mp02_node2_SOURCES = ../init.c ../task1.c ../system.h - -dist_rtems_tests_DATA = mp02-node2.scn -dist_rtems_tests_DATA += mp02-node2.doc - -include $(RTEMS_ROOT)/make/custom/@RTEMS_BSP@.cfg -include $(top_srcdir)/../automake/compile.am -include $(top_srcdir)/../automake/leaf.am - -AM_CPPFLAGS += -DNODE_NUMBER=2 -I$(srcdir)/.. - -AM_CPPFLAGS += -I$(top_srcdir)/../support/include - -LINK_OBJS = $(mp02_node2_OBJECTS) -LINK_LIBS = $(mp02_node2_LDLIBS) - -mp02-node2$(EXEEXT): $(mp02_node2_OBJECTS) $(mp02_node2_DEPENDENCIES) - @rm -f mp02-node2$(EXEEXT) - $(make-exe) - -include $(top_srcdir)/../automake/local.am diff --git a/testsuites/mptests/mp02/node2/mp02-node2.doc b/testsuites/mptests/mp02/node2/mp02-node2.doc deleted file mode 100644 index 981286480f..0000000000 --- a/testsuites/mptests/mp02/node2/mp02-node2.doc +++ /dev/null @@ -1,9 +0,0 @@ -# COPYRIGHT (c) 1989-1999. -# On-Line Applications Research Corporation (OAR). -# -# The license and distribution terms for this file may be -# found in the file LICENSE in this distribution or at -# http://www.rtems.org/license/LICENSE. -# - - diff --git a/testsuites/mptests/mp02/node2/mp02-node2.scn b/testsuites/mptests/mp02/node2/mp02-node2.scn deleted file mode 100644 index 233a910999..0000000000 --- a/testsuites/mptests/mp02/node2/mp02-node2.scn +++ /dev/null @@ -1,14 +0,0 @@ -*** TEST 2 -- NODE 2 *** -Creating Test_task (Global) -Starting Test_task (Global) -Deleting initialization task -Remote task's name is : 111 -Getting TID of remote task (all nodes) -Getting TID of remote task (1 node) -rtems_task_delete of remote task returned the correct error -rtems_task_start of remote task returned the correct error -rtems_task_restart of remote task returned the correct error -Setting notepad 2 of the remote task to 2 -Getting a notepad of the remote task -Remote notepad set and read correctly -*** END OF TEST 2 *** diff --git a/testsuites/mptests/mp02/system.h b/testsuites/mptests/mp02/system.h deleted file mode 100644 index 69025d4107..0000000000 --- a/testsuites/mptests/mp02/system.h +++ /dev/null @@ -1,46 +0,0 @@ -/* system.h - * - * This include file contains information that is included in every - * function in the test set. - * - * COPYRIGHT (c) 1989-1999. - * On-Line Applications Research Corporation (OAR). - * - * The license and distribution terms for this file may be - * found in the file LICENSE in this distribution or at - * http://www.rtems.org/license/LICENSE. - */ - -#include <tmacros.h> - -/* functions */ - -rtems_task Init( - rtems_task_argument argument -); - -rtems_task Test_task( - rtems_task_argument argument -); - -/* configuration information */ - -#define CONFIGURE_MP_APPLICATION - -#define CONFIGURE_APPLICATION_NEEDS_CONSOLE_DRIVER -#define CONFIGURE_APPLICATION_NEEDS_CLOCK_DRIVER - -#define CONFIGURE_ENABLE_CLASSIC_API_NOTEPADS - -#define CONFIGURE_MAXIMUM_TASKS 2 - -#define CONFIGURE_RTEMS_INIT_TASKS_TABLE - -#include <rtems/confdefs.h> - -/* variables */ - -TEST_EXTERN rtems_id Task_id[ 4 ]; /* array of task ids */ -TEST_EXTERN rtems_name Task_name[ 4 ]; /* array of task names */ - -/* end of include file */ diff --git a/testsuites/mptests/mp02/task1.c b/testsuites/mptests/mp02/task1.c deleted file mode 100644 index fbdcc0d65b..0000000000 --- a/testsuites/mptests/mp02/task1.c +++ /dev/null @@ -1,113 +0,0 @@ -/* Test_task - * - * This task tests the rtems_task_set_note directive on a remote task and that - * errors are returned when attempting to delete, start, or restart - * a remote task. - * - * Input parameters: - * argument - task argument - * - * Output parameters: NONE - * - * COPYRIGHT (c) 1989-2009. - * On-Line Applications Research Corporation (OAR). - * - * The license and distribution terms for this file may be - * found in the file LICENSE in this distribution or at - * http://www.rtems.org/license/LICENSE. - */ - -#ifdef HAVE_CONFIG_H -#include "config.h" -#endif - -#include "system.h" - -extern rtems_multiprocessing_table Multiprocessing_configuration; - -rtems_task Test_task( - rtems_task_argument argument -) -{ - rtems_id tid; - rtems_status_code status; - uint32_t remote_node; - rtems_id remote_tid; - rtems_id test_tid; - uint32_t note; - uint32_t tmpNode; - - status = rtems_task_ident( RTEMS_SELF, RTEMS_SEARCH_ALL_NODES, &tid ); - - remote_node = (Multiprocessing_configuration.node == 1) ? 2 : 1; - printf( "Remote task's name is : " ); - put_name( Task_name[ remote_node ], TRUE ); - - puts( "Getting TID of remote task (all nodes)" ); - do { - status = rtems_task_ident( - Task_name[ remote_node ], - RTEMS_SEARCH_ALL_NODES, - &remote_tid - ); - } while ( status != RTEMS_SUCCESSFUL ); - - directive_failed( status, "rtems_task_ident" ); - - puts( "Getting TID of remote task (1 node)" ); - status = rtems_task_ident( Task_name[ remote_node ], remote_node, &test_tid ); - directive_failed( status, "rtems_task_ident" ); - - if ( test_tid != remote_tid ) { - puts( "rtems_task_ident tid's do not match!!" ); - rtems_fatal_error_occurred( status ); - } - - status = rtems_task_delete( remote_tid ); - fatal_directive_status( - status, - RTEMS_ILLEGAL_ON_REMOTE_OBJECT, - "rtems_task_delete of remote task" - ); - puts( "rtems_task_delete of remote task returned the correct error" ); - - status = rtems_task_start( remote_tid, Test_task, 0 ); - fatal_directive_status( - status, - RTEMS_ILLEGAL_ON_REMOTE_OBJECT, - "rtems_task_start of remote task" - ); - puts( "rtems_task_start of remote task returned the correct error" ); - - status = rtems_task_restart( remote_tid, 0 ); - fatal_directive_status( - status, - RTEMS_ILLEGAL_ON_REMOTE_OBJECT, - "rtems_task_restart of remote task" - ); - puts( "rtems_task_restart of remote task returned the correct error" ); - - tmpNode = rtems_object_id_get_node(tid); - printf( "Setting notepad %" PRId32 " of the remote task to %" PRId32 "\n", tmpNode, tmpNode ); - status = rtems_task_set_note( remote_tid, tmpNode, tmpNode ); - directive_failed( status, "rtems_task_set_note" ); - - puts( "Getting a notepad of the remote task" ); - status = rtems_task_get_note( remote_tid, tmpNode, ¬e ); - directive_failed( status, "rtems_task_get_note" ); - - if ( note == tmpNode ) - puts( "Remote notepad set and read correctly" ); - else - printf( - "FAILURE!! Remote notepad was not set and read correctly (%" PRId32 ", %" PRId32 ")\n", - note, - tmpNode - ); - - status = rtems_task_wake_after( rtems_clock_get_ticks_per_second() ); - directive_failed( status, "rtems_task_wake_after" ); - - puts( "*** END OF TEST 2 ***" ); - rtems_test_exit( 0 ); -} |