diff options
author | Ralf Corsepius <ralf.corsepius@rtems.org> | 2003-11-11 00:58:28 +0000 |
---|---|---|
committer | Ralf Corsepius <ralf.corsepius@rtems.org> | 2003-11-11 00:58:28 +0000 |
commit | 5ada27d280649f5d0f5a1a27769a48f7483695c1 (patch) | |
tree | b3089902dbb5a7e90144314e9c4a1852d83bd382 /c/src/tests/sptests/sp09 | |
parent | 2003-11-10 Ralf Corsepius <corsepiu@faw.uni-ulm.de> (diff) | |
download | rtems-5ada27d280649f5d0f5a1a27769a48f7483695c1.tar.bz2 |
2003-11-10 Ralf Corsepius <corsepiu@faw.uni-ulm.de>
* sp01/.cvsignore: Remove.
* sp01/Makefile.am: Remove.
* sp01/init.c: Remove.
* sp01/sp01.doc: Remove.
* sp01/sp01.scn: Remove.
* sp01/system.h: Remove.
* sp01/task1.c: Remove.
* sp02/.cvsignore: Remove.
* sp02/Makefile.am: Remove.
* sp02/init.c: Remove.
* sp02/preempt.c: Remove.
* sp02/sp02.doc: Remove.
* sp02/sp02.scn: Remove.
* sp02/system.h: Remove.
* sp02/task1.c: Remove.
* sp02/task2.c: Remove.
* sp02/task3.c: Remove.
* .cvsignore: Remove.
* ChangeLog: Remove.
* Makefile.am: Remove.
* README: Remove.
* configure.ac: Remove.
* sptests.am: Remove.
* sp03/.cvsignore: Remove.
* sp03/Makefile.am: Remove.
* sp03/init.c: Remove.
* sp03/sp03.doc: Remove.
* sp03/sp03.scn: Remove.
* sp03/system.h: Remove.
* sp03/task1.c: Remove.
* sp03/task2.c: Remove.
* sp04/.cvsignore: Remove.
* sp04/Makefile.am: Remove.
* sp04/init.c: Remove.
* sp04/sp04.doc: Remove.
* sp04/sp04.scn: Remove.
* sp04/system.h: Remove.
* sp04/task1.c: Remove.
* sp04/task2.c: Remove.
* sp04/task3.c: Remove.
* sp04/tswitch.c: Remove.
* sp05/.cvsignore: Remove.
* sp05/Makefile.am: Remove.
* sp05/init.c: Remove.
* sp05/sp05.doc: Remove.
* sp05/sp05.scn: Remove.
* sp05/system.h: Remove.
* sp05/task1.c: Remove.
* sp05/task2.c: Remove.
* sp05/task3.c: Remove.
* sp06/.cvsignore: Remove.
* sp06/Makefile.am: Remove.
* sp06/init.c: Remove.
* sp06/sp06.doc: Remove.
* sp06/sp06.scn: Remove.
* sp06/system.h: Remove.
* sp06/task1.c: Remove.
* sp06/task2.c: Remove.
* sp06/task3.c: Remove.
* sp07/.cvsignore: Remove.
* sp07/Makefile.am: Remove.
* sp07/init.c: Remove.
* sp07/sp07.doc: Remove.
* sp07/sp07.scn: Remove.
* sp07/system.h: Remove.
* sp07/task1.c: Remove.
* sp07/task2.c: Remove.
* sp07/task3.c: Remove.
* sp07/task4.c: Remove.
* sp07/taskexit.c: Remove.
* sp07/tcreate.c: Remove.
* sp07/tdelete.c: Remove.
* sp07/trestart.c: Remove.
* sp07/tstart.c: Remove.
* sp08/.cvsignore: Remove.
* sp08/Makefile.am: Remove.
* sp08/init.c: Remove.
* sp08/sp08.doc: Remove.
* sp08/sp08.scn: Remove.
* sp08/system.h: Remove.
* sp08/task1.c: Remove.
* sp09/.cvsignore: Remove.
* sp09/Makefile.am: Remove.
* sp09/delay.c: Remove.
* sp09/init.c: Remove.
* sp09/isr.c: Remove.
* sp09/screen01.c: Remove.
* sp09/screen02.c: Remove.
* sp09/screen03.c: Remove.
* sp09/screen04.c: Remove.
* sp09/screen05.c: Remove.
* sp09/screen06.c: Remove.
* sp09/screen07.c: Remove.
* sp09/screen08.c: Remove.
* sp09/screen09.c: Remove.
* sp09/screen10.c: Remove.
* sp09/screen11.c: Remove.
* sp09/screen12.c: Remove.
* sp09/screen13.c: Remove.
* sp09/screen14.c: Remove.
* sp09/sp09.doc: Remove.
* sp09/sp09.scn: Remove.
* sp09/system.h: Remove.
* sp09/task1.c: Remove.
* sp09/task2.c: Remove.
* sp09/task3.c: Remove.
* sp09/task4.c: Remove.
* sp11/.cvsignore: Remove.
* sp11/Makefile.am: Remove.
* sp11/init.c: Remove.
* sp11/sp11.doc: Remove.
* sp11/sp11.scn: Remove.
* sp11/system.h: Remove.
* sp11/task1.c: Remove.
* sp11/task2.c: Remove.
* sp11/timer.c: Remove.
* sp12/.cvsignore: Remove.
* sp12/Makefile.am: Remove.
* sp12/init.c: Remove.
* sp12/pridrv.c: Remove.
* sp12/pritask.c: Remove.
* sp12/sp12.doc: Remove.
* sp12/sp12.scn: Remove.
* sp12/system.h: Remove.
* sp12/task1.c: Remove.
* sp12/task2.c: Remove.
* sp12/task3.c: Remove.
* sp12/task4.c: Remove.
* sp12/task5.c: Remove.
* sp13/.cvsignore: Remove.
* sp13/Makefile.am: Remove.
* sp13/fillbuff.c: Remove.
* sp13/init.c: Remove.
* sp13/putbuff.c: Remove.
* sp13/sp13.doc: Remove.
* sp13/sp13.scn: Remove.
* sp13/system.h: Remove.
* sp13/task1.c: Remove.
* sp13/task2.c: Remove.
* sp13/task3.c: Remove.
* sp14/.cvsignore: Remove.
* sp14/Makefile.am: Remove.
* sp14/asr.c: Remove.
* sp14/init.c: Remove.
* sp14/sp14.doc: Remove.
* sp14/sp14.scn: Remove.
* sp14/system.h: Remove.
* sp14/task1.c: Remove.
* sp14/task2.c: Remove.
* sp15/.cvsignore: Remove.
* sp15/Makefile.am: Remove.
* sp15/init.c: Remove.
* sp15/sp15.doc: Remove.
* sp15/sp15.scn: Remove.
* sp15/system.h: Remove.
* sp15/task1.c: Remove.
* sp16/.cvsignore: Remove.
* sp16/Makefile.am: Remove.
* sp16/init.c: Remove.
* sp16/sp16.doc: Remove.
* sp16/sp16.scn: Remove.
* sp16/system.h: Remove.
* sp16/task1.c: Remove.
* sp16/task2.c: Remove.
* sp16/task3.c: Remove.
* sp16/task4.c: Remove.
* sp16/task5.c: Remove.
* sp17/.cvsignore: Remove.
* sp17/Makefile.am: Remove.
* sp17/asr.c: Remove.
* sp17/init.c: Remove.
* sp17/sp17.doc: Remove.
* sp17/sp17.scn: Remove.
* sp17/system.h: Remove.
* sp17/task1.c: Remove.
* sp17/task2.c: Remove.
* sp19/.cvsignore: Remove.
* sp19/Makefile.am: Remove.
* sp19/first.c: Remove.
* sp19/fptask.c: Remove.
* sp19/fptest.h: Remove.
* sp19/init.c: Remove.
* sp19/inttest.h: Remove.
* sp19/sp19.doc: Remove.
* sp19/sp19.scn: Remove.
* sp19/system.h: Remove.
* sp19/task1.c: Remove.
* sp20/.cvsignore: Remove.
* sp20/Makefile.am: Remove.
* sp20/getall.c: Remove.
* sp20/init.c: Remove.
* sp20/sp20.doc: Remove.
* sp20/sp20.scn: Remove.
* sp20/system.h: Remove.
* sp20/task1.c: Remove.
* sp21/.cvsignore: Remove.
* sp21/Makefile.am: Remove.
* sp21/init.c: Remove.
* sp21/sp21.doc: Remove.
* sp21/sp21.scn: Remove.
* sp21/system.h: Remove.
* sp21/task1.c: Remove.
* sp22/.cvsignore: Remove.
* sp22/Makefile.am: Remove.
* sp22/delay.c: Remove.
* sp22/init.c: Remove.
* sp22/prtime.c: Remove.
* sp22/sp22.doc: Remove.
* sp22/sp22.scn: Remove.
* sp22/system.h: Remove.
* sp22/task1.c: Remove.
* sp23/.cvsignore: Remove.
* sp23/Makefile.am: Remove.
* sp23/init.c: Remove.
* sp23/sp23.doc: Remove.
* sp23/sp23.scn: Remove.
* sp23/system.h: Remove.
* sp23/task1.c: Remove.
* sp24/.cvsignore: Remove.
* sp24/Makefile.am: Remove.
* sp24/init.c: Remove.
* sp24/resume.c: Remove.
* sp24/sp24.doc: Remove.
* sp24/sp24.scn: Remove.
* sp24/system.h: Remove.
* sp24/task1.c: Remove.
* sp25/.cvsignore: Remove.
* sp25/Makefile.am: Remove.
* sp25/init.c: Remove.
* sp25/sp25.doc: Remove.
* sp25/sp25.scn: Remove.
* sp25/system.h: Remove.
* sp25/task1.c: Remove.
* sp26/.cvsignore: Remove.
* sp26/Makefile.am: Remove.
* sp26/init.c: Remove.
* sp26/sp26.doc: Remove.
* sp26/sp26.scn: Remove.
* sp26/system.h: Remove.
* sp26/task1.c: Remove.
* sp27/.cvsignore: Remove.
* sp27/Makefile.am: Remove.
* sp27/init.c: Remove.
* sp27/sp27.doc: Remove.
* sp27/sp27.scn: Remove.
* sp28/.cvsignore: Remove.
* sp28/Makefile.am: Remove.
* sp28/init.c: Remove.
* sp28/sp28.doc: Remove.
* sp28/sp28.scn: Remove.
* sp29/.cvsignore: Remove.
* sp29/Makefile.am: Remove.
* sp29/init.c: Remove.
* sp29/sp29.doc: Remove.
* sp29/sp29.scn: Remove.
* sp30/.cvsignore: Remove.
* sp30/Makefile.am: Remove.
* sp30/init.c: Remove.
* sp30/resume.c: Remove.
* sp30/sp30.doc: Remove.
* sp30/sp30.scn: Remove.
* sp30/system.h: Remove.
* sp30/task1.c: Remove.
* sp31/.cvsignore: Remove.
* sp31/Makefile.am: Remove.
* sp31/delay.c: Remove.
* sp31/init.c: Remove.
* sp31/prtime.c: Remove.
* sp31/sp31.doc: Remove.
* sp31/sp31.scn: Remove.
* sp31/system.h: Remove.
* sp31/task1.c: Remove.
* sp32/.cvsignore: Remove.
* sp32/Makefile.am: Remove.
* sp32/init.c: Remove.
* sp32/sp32.scn: Remove.
* spfatal/.cvsignore: Remove.
* spfatal/Makefile.am: Remove.
* spfatal/README: Remove.
* spfatal/fatal.c: Remove.
* spfatal/init.c: Remove.
* spfatal/puterr.c: Remove.
* spfatal/spfatal.doc: Remove.
* spfatal/spfatal.scn: Remove.
* spfatal/system.h: Remove.
* spfatal/task1.c: Remove.
* spsize/.cvsignore: Remove.
* spsize/Makefile.am: Remove.
* spsize/getint.c: Remove.
* spsize/init.c: Remove.
* spsize/size.c: Remove.
* spsize/size.scn: Remove.
* spsize/system.h: Remove.
Diffstat (limited to '')
26 files changed, 0 insertions, 3464 deletions
diff --git a/c/src/tests/sptests/sp09/.cvsignore b/c/src/tests/sptests/sp09/.cvsignore deleted file mode 100644 index 282522db03..0000000000 --- a/c/src/tests/sptests/sp09/.cvsignore +++ /dev/null @@ -1,2 +0,0 @@ -Makefile -Makefile.in diff --git a/c/src/tests/sptests/sp09/Makefile.am b/c/src/tests/sptests/sp09/Makefile.am deleted file mode 100644 index 5b78ac0804..0000000000 --- a/c/src/tests/sptests/sp09/Makefile.am +++ /dev/null @@ -1,42 +0,0 @@ -## -## $Id$ -## - - -TEST = sp09 - -MANAGERS = io message dual_ported_memory event multi_processor region \ - semaphore signal rate_monotonic timer partition - -C_FILES = init.c delay.c isr.c screen01.c screen02.c screen03.c screen04.c \ - screen05.c screen06.c screen07.c screen08.c screen09.c screen10.c \ - screen11.c screen12.c screen13.c screen14.c task1.c task2.c task3.c \ - task4.c -C_O_FILES = $(C_FILES:%.c=${ARCH}/%.$(OBJEXT)) - -H_FILES = system.h -noinst_HEADERS = $(H_FILES) - -DOCTYPES = scn doc -DOCS = $(DOCTYPES:%=$(TEST).%) - -SRCS = $(C_FILES) $(H_FILES) -OBJS = $(C_O_FILES) - -PRINT_SRCS = $(DOCS) - -PGM = ${ARCH}/$(TEST).exe - -include $(RTEMS_ROOT)/make/custom/@RTEMS_BSP@.cfg -include $(top_srcdir)/../automake/compile.am -include $(top_srcdir)/../automake/leaf.am -include $(top_srcdir)/sptests.am - -${PGM}: $(OBJS) $(LINK_FILES) - $(make-exe) - -all-local: $(ARCH) $(TMPINSTALL_FILES) - -EXTRA_DIST = $(C_FILES) $(DOCS) - -include $(top_srcdir)/../automake/local.am diff --git a/c/src/tests/sptests/sp09/delay.c b/c/src/tests/sptests/sp09/delay.c deleted file mode 100644 index db448d53e8..0000000000 --- a/c/src/tests/sptests/sp09/delay.c +++ /dev/null @@ -1,27 +0,0 @@ -/* Delayed_routine - * - * This routine is used as the timer routine for Timer Manager tests. - * - * Input parameters: - * ignored - this parameter is ignored - * - * 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.com/license/LICENSE. - * - * $Id$ - */ - -#include "system.h" - -rtems_timer_service_routine Delayed_routine( - rtems_id ignored_id, - void *ignored_address -) -{ -} diff --git a/c/src/tests/sptests/sp09/init.c b/c/src/tests/sptests/sp09/init.c deleted file mode 100644 index 91ece0204e..0000000000 --- a/c/src/tests/sptests/sp09/init.c +++ /dev/null @@ -1,119 +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.com/license/LICENSE. - * - * $Id$ - */ - -#define TEST_INIT -#include "system.h" - -rtems_task Init( - rtems_task_argument argument -) -{ - rtems_status_code status; - - puts( "\n\n*** TEST 9 ***" ); - - Task_name[ 1 ] = rtems_build_name( 'T', 'A', '1', ' ' ); - Task_name[ 2 ] = rtems_build_name( 'T', 'A', '2', ' ' ); - Task_name[ 3 ] = rtems_build_name( 'T', 'A', '3', ' ' ); - Task_name[ 4 ] = rtems_build_name( 'T', 'A', '4', ' ' ); - Task_name[ 5 ] = rtems_build_name( 'T', 'A', '5', ' ' ); - Task_name[ 6 ] = rtems_build_name( 'T', 'A', '6', ' ' ); - Task_name[ 7 ] = rtems_build_name( 'T', 'A', '7', ' ' ); - Task_name[ 8 ] = rtems_build_name( 'T', 'A', '8', ' ' ); - Task_name[ 9 ] = rtems_build_name( 'T', 'A', '9', ' ' ); - Task_name[ 10 ] = rtems_build_name( 'T', 'A', 'A', ' ' ); - - Timer_name[ 1 ] = rtems_build_name( 'T', 'M', '1', ' ' ); - - Semaphore_name[ 1 ] = rtems_build_name( 'S', 'M', '1', ' ' ); - Semaphore_name[ 2 ] = rtems_build_name( 'S', 'M', '2', ' ' ); - Semaphore_name[ 3 ] = rtems_build_name( 'S', 'M', '3', ' ' ); - - Queue_name[ 1 ] = rtems_build_name( 'M', 'Q', '1', ' ' ); - Queue_name[ 2 ] = rtems_build_name( 'M', 'Q', '2', ' ' ); - - Partition_name[ 1 ] = rtems_build_name( 'P', 'T', '1', ' ' ); - - Region_name[ 1 ] = rtems_build_name( 'R', 'N', '1', ' ' ); - - Port_name[ 1 ] = rtems_build_name( 'D', 'P', '1', ' ' ); - - Period_name[ 1 ] = rtems_build_name( 'T', 'M', '1', ' ' ); - -#if 0 - status = rtems_task_create( - Task_name[1], - 4, - 10, - RTEMS_DEFAULT_MODES, - RTEMS_DEFAULT_ATTRIBUTES, - &Task_id[ 1 ] - ); - fatal_directive_status( - status, - RTEMS_INVALID_SIZE, - "rtems_task_create with illegal stack size" - ); - puts( "INIT - rtems_task_create - RTEMS_INVALID_SIZE" ); -#endif - puts( "INIT - rtems_task_create - RTEMS_INVALID_SIZE -- NOT CHECKED" ); - - status = rtems_task_create( - Task_name[1], - 0, - RTEMS_MINIMUM_STACK_SIZE, - RTEMS_DEFAULT_MODES, - RTEMS_DEFAULT_ATTRIBUTES, - &Task_id[ 1 ] - ); - fatal_directive_status( - status, - RTEMS_INVALID_PRIORITY, - "rtems_task_create with illegal priority" - ); - puts( "INIT - rtems_task_create - RTEMS_INVALID_PRIORITY" ); - - status = rtems_task_create( - Task_name[ 1 ], - 4, - RTEMS_MINIMUM_STACK_SIZE * 3, - RTEMS_DEFAULT_MODES, - RTEMS_DEFAULT_ATTRIBUTES, - &Task_id[ 1 ] - ); - directive_failed( status, "rtems_task_create of TA1" ); - - status = rtems_task_restart( Task_id[ 1 ], 0 ); - fatal_directive_status( - status, - RTEMS_INCORRECT_STATE, - "rtems_task_restart of DORMANT task" - ); - puts( "INIT - rtems_task_restart - RTEMS_INCORRECT_STATE" ); - - status = rtems_task_start( Task_id[ 1 ], Task_1, 0 ); - directive_failed( status, "rtems_task_start of TA1" ); - - status = rtems_task_delete( RTEMS_SELF ); - directive_failed( status, "rtems_task_delete of RTEMS_SELF" ); -} diff --git a/c/src/tests/sptests/sp09/isr.c b/c/src/tests/sptests/sp09/isr.c deleted file mode 100644 index 9185aac431..0000000000 --- a/c/src/tests/sptests/sp09/isr.c +++ /dev/null @@ -1,26 +0,0 @@ -/* Service_routine - * - * This routine is used as the timer routine for Interrupt Manager tests. - * - * Input parameters: - * ignored - this parameter is ignored - * - * 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.com/license/LICENSE. - * - * $Id$ - */ - -#include "system.h" - -rtems_isr Service_routine( - rtems_vector_number ignored -) -{ -} diff --git a/c/src/tests/sptests/sp09/screen01.c b/c/src/tests/sptests/sp09/screen01.c deleted file mode 100644 index 3df65070d7..0000000000 --- a/c/src/tests/sptests/sp09/screen01.c +++ /dev/null @@ -1,179 +0,0 @@ -/* Screen1 - * - * This routine generates error screen 1 for test 9. - * - * Input parameters: NONE - * - * 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.com/license/LICENSE. - * - * $Id$ - */ - -#include "system.h" - -void Screen1() -{ - rtems_unsigned32 notepad_value; - rtems_id self_id; - rtems_task_priority previous_priority; - rtems_status_code status; - - status = rtems_task_delete( 100 ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_task_delete with illegal id" - ); - puts( "TA1 - rtems_task_delete - RTEMS_INVALID_ID" ); - - status = rtems_task_get_note( RTEMS_SELF, 100, ¬epad_value ); - fatal_directive_status( - status, - RTEMS_INVALID_NUMBER, - "rtems_task_get_note with illegal notepad" - ); - puts( "TA1 - rtems_task_get_note - RTEMS_INVALID_NUMBER" ); - - status = rtems_task_get_note( 100, RTEMS_NOTEPAD_LAST, ¬epad_value ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_task_get_note with illegal id" - ); - puts( "TA1 - rtems_task_get_note - RTEMS_INVALID_ID" ); - - status = rtems_task_ident( RTEMS_SELF, RTEMS_SEARCH_ALL_NODES, &self_id ); - directive_failed( status, "rtems_task_ident of self" ); - - if ( self_id != Task_id[ 1 ] ) { - puts( "ERROR - rtems_task_ident - incorrect ID returned!" ); - } - puts( "TA1 - rtems_task_ident - current task RTEMS_SUCCESSFUL" ); - - status = rtems_task_ident( 100, RTEMS_SEARCH_ALL_NODES, &Junk_id ); - fatal_directive_status( - status, - RTEMS_INVALID_NAME, - "rtems_task_ident with illegal name (local)" - ); - puts( "TA1 - rtems_task_ident - global RTEMS_INVALID_NAME" ); - - status = rtems_task_ident( 100, 1, &Junk_id ); - fatal_directive_status( - status, - RTEMS_INVALID_NAME, - "rtems_task_ident with illegal name (global)" - ); - puts( "TA1 - rtems_task_ident - local RTEMS_INVALID_NAME" ); - - /* - * This one case is different if MP is enabled/disabled. - */ - - status = rtems_task_ident( 100, 2, &Junk_id ); -#if defined(RTEMS_MULTIPROCESSING) - fatal_directive_status( - status, - RTEMS_INVALID_NODE, - "rtems_task_ident with illegal node" - ); -#else - fatal_directive_status( - status, - RTEMS_INVALID_NAME, - "rtems_task_ident with illegal node" - ); -#endif - puts( "TA1 - rtems_task_ident - RTEMS_INVALID_NODE" ); - - status = rtems_task_restart( 100, 0 ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_task_restart with illegal id" - ); - puts( "TA1 - rtems_task_restart - RTEMS_INVALID_ID" ); - - status = rtems_task_resume( 100 ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_task_resume with illegal id" - ); - puts( "TA1 - rtems_task_resume - RTEMS_INVALID_ID" ); - - status = rtems_task_resume( RTEMS_SELF ); - fatal_directive_status( - status, - RTEMS_INCORRECT_STATE, - "rtems_task_resume of ready task" - ); - puts( "TA1 - rtems_task_resume - RTEMS_INCORRECT_STATE" ); - - status = rtems_task_set_priority( RTEMS_SELF, 512, &previous_priority ); - fatal_directive_status( - status, - RTEMS_INVALID_PRIORITY, - "rtems_task_set_priority with illegal priority" - ); - puts( "TA1 - rtems_task_set_priority - RTEMS_INVALID_PRIORITY" ); - - status = rtems_task_set_priority( 100, 8, &previous_priority ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_task_set_priority with illegal id" - ); - puts( "TA1 - rtems_task_set_priority - RTEMS_INVALID_ID" ); - - status = rtems_task_set_note( - RTEMS_SELF, - RTEMS_NOTEPAD_LAST+10, - notepad_value - ); - fatal_directive_status( - status, - RTEMS_INVALID_NUMBER, - "rtems_task_set_note with illegal notepad" - ); - puts( "TA1 - rtems_task_set_note - RTEMS_INVALID_NUMBER" ); - - status = rtems_task_set_note( 100, RTEMS_NOTEPAD_LAST, notepad_value ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_task_set_note with illegal id" - ); - puts( "TA1 - rtems_task_set_note - RTEMS_INVALID_ID" ); - - status = rtems_task_start( 100, Task_1, 0 ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_task_start with illegal id" - ); - puts( "TA1 - rtems_task_start - RTEMS_INVALID_ID" ); - - status = rtems_task_start( 0, Task_1, 0 ); - fatal_directive_status( - status, - RTEMS_INCORRECT_STATE, - "rtems_task_start of ready task" - ); - puts( "TA1 - rtems_task_start - RTEMS_INCORRECT_STATE" ); - - status = rtems_task_suspend( 100 ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_task_suspend with illegal id" - ); - puts( "TA1 - rtems_task_suspend - RTEMS_INVALID_ID" ); -} diff --git a/c/src/tests/sptests/sp09/screen02.c b/c/src/tests/sptests/sp09/screen02.c deleted file mode 100644 index a7d0dcd029..0000000000 --- a/c/src/tests/sptests/sp09/screen02.c +++ /dev/null @@ -1,191 +0,0 @@ -/* Screen2 - * - * This routine generates error screen 2 for test 9. - * - * Input parameters: NONE - * - * 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.com/license/LICENSE. - * - * $Id$ - */ - -#include "system.h" - -void Screen2() -{ - rtems_time_of_day time; - rtems_status_code status; - -/* errors before clock is set */ - - status = rtems_clock_get( RTEMS_CLOCK_GET_TOD, &time ); - if ( status == RTEMS_SUCCESSFUL ) { - puts( - "TA1 - rtems_clock_get - RTEMS_NOT_DEFINED -- DID BSP SET THE TIME OF DAY?" - ); - } else { - fatal_directive_status( - status, - RTEMS_NOT_DEFINED, - "rtems_clock_get before clock is set" - ); - puts( "TA1 - rtems_clock_get - RTEMS_NOT_DEFINED" ); - } - - status = rtems_task_wake_when( &time ); - if ( status == RTEMS_SUCCESSFUL ) { - puts( -"TA1 - rtems_task_wake_when - RTEMS_NOT_DEFINED -- DID BSP SET THE TIME OF DAY?" - ); - } else { - fatal_directive_status( - status, - RTEMS_NOT_DEFINED, - "rtems_task_wake_when before clock is set" - ); - puts( "TA1 - rtems_task_wake_when - RTEMS_NOT_DEFINED" ); - } - - status = rtems_timer_fire_when( 0, &time, Delayed_routine, NULL ); - if ( status == RTEMS_SUCCESSFUL ) { - puts( - "TA1 - timer_wake_when - RTEMS_NOT_DEFINED -- DID BSP SET THE TIME OF DAY?" - ); - } else { - fatal_directive_status( - status, - RTEMS_NOT_DEFINED, - "task_fire_when before clock is set" - ); - puts( "TA1 - rtems_timer_fire_when - RTEMS_NOT_DEFINED" ); - } - - build_time( &time, 2, 5, 1987, 8, 30, 45, 0 ); - print_time( "TA1 - rtems_clock_set - ", &time, "" ); - status = rtems_clock_set( &time ); - fatal_directive_status( - status, - RTEMS_INVALID_CLOCK, - "rtems_clock_set with invalid year" - ); - puts( " - RTEMS_INVALID_CLOCK" ); - - build_time( &time, 15, 5, 1988, 8, 30, 45, 0 ); - print_time( "TA1 - rtems_clock_set - ", &time, "" ); - status = rtems_clock_set( &time ); - fatal_directive_status( - status, - RTEMS_INVALID_CLOCK, - "rtems_clock_set with invalid month" - ); - puts( " - RTEMS_INVALID_CLOCK" ); - - build_time( &time, 2, 32, 1988, 8, 30, 45, 0 ); - print_time( "TA1 - rtems_clock_set - ", &time, "" ); - status = rtems_clock_set( &time ); - fatal_directive_status( - status, - RTEMS_INVALID_CLOCK, - "rtems_clock_set with invalid day" - ); - puts( " - RTEMS_INVALID_CLOCK" ); - - build_time( &time, 2, 5, 1988, 25, 30, 45, 0 ); - print_time( "TA1 - rtems_clock_set - ", &time, "" ); - status = rtems_clock_set( &time ); - fatal_directive_status( - status, - RTEMS_INVALID_CLOCK, - "rtems_clock_set with invalid hour" - ); - puts( " - RTEMS_INVALID_CLOCK" ); - - build_time( &time, 2, 5, 1988, 8, 61, 45, 0 ); - print_time( "TA1 - rtems_clock_set - ", &time, "" ); - status = rtems_clock_set( &time ); - fatal_directive_status( - status, - RTEMS_INVALID_CLOCK, - "rtems_clock_set with invalid minute" - ); - puts( " - RTEMS_INVALID_CLOCK" ); - - build_time( &time, 2, 5, 1988, 8, 30, 61, 0 ); - print_time( "TA1 - rtems_clock_set - ", &time, "" ); - status = rtems_clock_set( &time ); - fatal_directive_status( - status, - RTEMS_INVALID_CLOCK, - "rtems_clock_set with invalid second" - ); - puts( " - RTEMS_INVALID_CLOCK" ); - - build_time( &time, 2, 5, 1988, 8, 30, 45, TICKS_PER_SECOND + 1 ); - print_time( "TA1 - rtems_clock_set - ", &time, "" ); - status = rtems_clock_set( &time ); - fatal_directive_status( - status, - RTEMS_INVALID_CLOCK, - "rtems_clock_set with invalid ticks per second" - ); - puts( " - RTEMS_INVALID_CLOCK" ); - - build_time( &time, 2, 5, 1988, 8, 30, 45, 0 ); - print_time( "TA1 - rtems_clock_set - ", &time, "" ); - status = rtems_clock_set( &time ); - directive_failed( status, "rtems_clock_set successful" ); - puts( " - RTEMS_SUCCESSFUL" ); - -/* rtems_task_wake_when */ - - build_time( &time, 2, 5, 1988, 8, 30, 48, TICKS_PER_SECOND + 1 ); - time.second += 3; - puts( "TA1 - rtems_task_wake_when - TICKINVALID - sleep about 3 seconds" ); - - status = rtems_task_wake_when( &time ); - directive_failed( - status, - "rtems_task_wake_when with invalid ticks per second" - ); - puts( "TA1 - rtems_task_wake_when - TICKINVALID - woke up RTEMS_SUCCESSFUL" ); - - build_time( &time, 2, 5, 1961, 8, 30, 48, 0 ); - print_time( "TA1 - rtems_task_wake_when - ", &time, "" ); - status = rtems_task_wake_when( &time ); - fatal_directive_status( - status, - RTEMS_INVALID_CLOCK, - "rtems_task_wake_when with invalid year" - ); - puts( " - RTEMS_INVALID_CLOCK" ); - - build_time( &time, 2, 5, 1988, 25, 30, 48, 0 ); - print_time( "TA1 - rtems_task_wake_when - ", &time, "" ); - status = rtems_task_wake_when( &time ); - fatal_directive_status( - status, - RTEMS_INVALID_CLOCK, - "rtems_task_wake_when with invalid hour" - ); - puts( " - RTEMS_INVALID_CLOCK" ); - - rtems_clock_get( RTEMS_CLOCK_GET_TOD, &time ); - print_time( "TA1 - current time - ", &time, "\n" ); - - time.month = 1; - print_time( "TA1 - rtems_task_wake_when - ", &time, "" ); - status = rtems_task_wake_when( &time ); - fatal_directive_status( - status, - RTEMS_INVALID_CLOCK, - "rtems_task_wake_when before current time" - ); - puts( " - RTEMS_INVALID_CLOCK" ); -} diff --git a/c/src/tests/sptests/sp09/screen03.c b/c/src/tests/sptests/sp09/screen03.c deleted file mode 100644 index 0a119ea554..0000000000 --- a/c/src/tests/sptests/sp09/screen03.c +++ /dev/null @@ -1,217 +0,0 @@ -/* Screen3 - * - * This routine generates error screen 3 for test 9. - * - * Input parameters: NONE - * - * 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.com/license/LICENSE. - * - * $Id$ - */ - -#include "system.h" - -void Screen3() -{ - rtems_name task_name; - rtems_status_code status; - - task_name = 1; - status = rtems_task_create( - 0, - 1, - RTEMS_MINIMUM_STACK_SIZE, - RTEMS_DEFAULT_MODES, - RTEMS_DEFAULT_ATTRIBUTES, - &Junk_id - ); - fatal_directive_status( - status, - RTEMS_INVALID_NAME, - "rtems_task_create with illegal name" - ); - puts( "TA1 - rtems_task_create - RTEMS_INVALID_NAME" ); - - /* - * If the bsp provides its own stack allocator, then - * skip the test that tries to allocate a stack that is too big. - */ - - if (rtems_cpu_configuration_get_stack_allocate_hook()) { - puts( "TA1 - rtems_task_create - stack size - RTEMS_UNSATISFIED -- SKIPPED" ); - } else { - status = rtems_task_create( - task_name, - 1, - rtems_configuration_get_work_space_size(), - RTEMS_DEFAULT_MODES, - RTEMS_DEFAULT_ATTRIBUTES, - &Junk_id - ); - fatal_directive_status( - status, - RTEMS_UNSATISFIED, - "rtems_task_create with a stack size larger than the workspace" - ); - puts( "TA1 - rtems_task_create - stack size - RTEMS_UNSATISFIED" ); - } - - status = rtems_task_create( - Task_name[ 2 ], - 4, - RTEMS_MINIMUM_STACK_SIZE, - RTEMS_DEFAULT_MODES, - RTEMS_DEFAULT_ATTRIBUTES, - &Task_id[ 2 ] - ); - directive_failed( status, "rtems_task_create of TA2" ); - puts( "TA1 - rtems_task_create - TA2 created - RTEMS_SUCCESSFUL" ); - - status = rtems_task_suspend( Task_id[ 2 ] ); - directive_failed( status, "rtems_task_suspend of TA2" ); - puts( "TA1 - rtems_task_suspend - suspend TA2 - RTEMS_SUCCESSFUL" ); - - status = rtems_task_suspend( Task_id[ 2 ] ); - fatal_directive_status( - status, - RTEMS_ALREADY_SUSPENDED, - "rtems_task_suspend of suspended TA2" - ); - puts( "TA1 - rtems_task_suspend - suspend TA2 - RTEMS_ALREADY_SUSPENDED" ); - - status = rtems_task_resume( Task_id[ 2 ] ); - directive_failed( status, "rtems_task_resume of TA2" ); - puts( "TA1 - rtems_task_resume - TA2 resumed - RTEMS_SUCCESSFUL" ); - - status = rtems_task_create( - Task_name[ 3 ], - 4, - RTEMS_MINIMUM_STACK_SIZE, - RTEMS_DEFAULT_MODES, - RTEMS_DEFAULT_ATTRIBUTES, - &Task_id[ 3 ] - ); - directive_failed( status, "rtems_task_create of TA3" ); - puts( "TA1 - rtems_task_create - TA3 created - RTEMS_SUCCESSFUL" ); - - status = rtems_task_create( - Task_name[ 4 ], - 4, - RTEMS_MINIMUM_STACK_SIZE, - RTEMS_DEFAULT_MODES, - RTEMS_DEFAULT_ATTRIBUTES, - &Task_id[ 4 ] - ); - directive_failed( status, "rtems_task_create of TA4" ); - puts( "TA1 - rtems_task_create - 4 created - RTEMS_SUCCESSFUL" ); - - status = rtems_task_create( - Task_name[ 5 ], - 4, - RTEMS_MINIMUM_STACK_SIZE, - RTEMS_DEFAULT_MODES, - RTEMS_DEFAULT_ATTRIBUTES, - &Task_id[ 5 ] - ); - directive_failed( status, "rtems_task_create of TA5" ); - puts( "TA1 - rtems_task_create - 5 created - RTEMS_SUCCESSFUL" ); - - status = rtems_task_create( - Task_name[ 6 ], - 4, - RTEMS_MINIMUM_STACK_SIZE, - RTEMS_DEFAULT_MODES, - RTEMS_DEFAULT_ATTRIBUTES, - &Task_id[ 6 ] - ); - directive_failed( status, "rtems_task_create of TA6" ); - puts( "TA1 - rtems_task_create - 6 created - RTEMS_SUCCESSFUL" ); - - status = rtems_task_create( - Task_name[ 7 ], - 4, - RTEMS_MINIMUM_STACK_SIZE, - RTEMS_DEFAULT_MODES, - RTEMS_DEFAULT_ATTRIBUTES, - &Task_id[ 7 ] - ); - directive_failed( status, "rtems_task_create of TA7" ); - puts( "TA1 - rtems_task_create - 7 created - RTEMS_SUCCESSFUL" ); - - status = rtems_task_create( - Task_name[ 8 ], - 4, - RTEMS_MINIMUM_STACK_SIZE, - RTEMS_DEFAULT_MODES, - RTEMS_DEFAULT_ATTRIBUTES, - &Task_id[ 8 ] - ); - directive_failed( status, "rtems_task_create of TA8" ); - puts( "TA1 - rtems_task_create - 8 created - RTEMS_SUCCESSFUL" ); - - status = rtems_task_create( - Task_name[ 9 ], - 4, - RTEMS_MINIMUM_STACK_SIZE, - RTEMS_DEFAULT_MODES, - RTEMS_DEFAULT_ATTRIBUTES, - &Task_id[ 9 ] - ); - directive_failed( status, "rtems_task_create of TA9" ); - puts( "TA1 - rtems_task_create - 9 created - RTEMS_SUCCESSFUL" ); - - status = rtems_task_create( - Task_name[ 10 ], - 4, - RTEMS_MINIMUM_STACK_SIZE, - RTEMS_DEFAULT_MODES, - RTEMS_DEFAULT_ATTRIBUTES, - &Task_id[ 10 ] - ); - directive_failed( status, "rtems_task_create of TA10" ); - puts( "TA1 - rtems_task_create - 10 created - RTEMS_SUCCESSFUL" ); - - status = rtems_task_create( - task_name, - 4, - RTEMS_MINIMUM_STACK_SIZE, - RTEMS_DEFAULT_MODES, - RTEMS_DEFAULT_ATTRIBUTES, - &Junk_id - ); - fatal_directive_status( - status, - RTEMS_TOO_MANY, - "rtems_task_create for too many tasks" - ); - puts( "TA1 - rtems_task_create - 11 - RTEMS_TOO_MANY" ); - - /* - * The check for an object being global is only made if - * multiprocessing is enabled. - */ - -#if defined(RTEMS_MULTIPROCESSING) - status = rtems_task_create( - task_name, - 4, - RTEMS_MINIMUM_STACK_SIZE, - RTEMS_DEFAULT_MODES, - RTEMS_GLOBAL, - &Junk_id - ); - fatal_directive_status( - status, - RTEMS_MP_NOT_CONFIGURED, - "rtems_task_create of global task in a single cpu system" - ); -#endif - puts( "TA1 - rtems_task_create - RTEMS_MP_NOT_CONFIGURED" ); -} diff --git a/c/src/tests/sptests/sp09/screen04.c b/c/src/tests/sptests/sp09/screen04.c deleted file mode 100644 index f9021b55ce..0000000000 --- a/c/src/tests/sptests/sp09/screen04.c +++ /dev/null @@ -1,84 +0,0 @@ -/* Screen4 - * - * This routine generates error screen 4 for test 9. - * - * Input parameters: NONE - * - * 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.com/license/LICENSE. - * - * $Id$ - */ - -#include "system.h" - -void Screen4() -{ - rtems_event_set event_out; - rtems_time_of_day time; - rtems_status_code status; - - status = rtems_event_receive( - RTEMS_EVENT_16, - RTEMS_NO_WAIT, - RTEMS_NO_TIMEOUT, - &event_out - ); - fatal_directive_status( - status, - RTEMS_UNSATISFIED, - "rtems_event_receive unsatisfied (ALL)" - ); - puts( "TA1 - rtems_event_receive - RTEMS_UNSATISFIED ( all conditions )" ); - - status = rtems_event_receive( - RTEMS_EVENT_16, - RTEMS_EVENT_ANY | RTEMS_NO_WAIT, - RTEMS_NO_TIMEOUT, - &event_out - ); - fatal_directive_status( - status, - RTEMS_UNSATISFIED, - "rtems_event_receive unsatisfied (ANY)" - ); - puts( "TA1 - rtems_event_receive - RTEMS_UNSATISFIED ( any condition )" ); - - puts( "TA1 - rtems_event_receive - timeout in 3 seconds" ); - status = rtems_event_receive( - RTEMS_EVENT_16, - RTEMS_DEFAULT_OPTIONS, - 3 * TICKS_PER_SECOND, - &event_out - ); - fatal_directive_status( - status, - RTEMS_TIMEOUT, - "rtems_event_receive" - ); - puts( "TA1 - rtems_event_receive - woke up with RTEMS_TIMEOUT" ); - - status = rtems_event_send( 100, RTEMS_EVENT_16 ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_event_send with illegal id" - ); - puts( "TA1 - rtems_event_send - RTEMS_INVALID_ID" ); - - puts( "TA1 - rtems_task_wake_after - sleep 1 second - RTEMS_SUCCESSFUL" ); - status = rtems_task_wake_after( TICKS_PER_SECOND ); - directive_failed( status, "rtems_task_wake_after" ); - - build_time( &time, 2, 5, 1988, 8, 30, 45, 0 ); - print_time( "TA1 - rtems_clock_set - ", &time, "" ); - status = rtems_clock_set( &time ); - directive_failed( status, "rtems_clock_set" ); - puts( " - RTEMS_SUCCESSFUL" ); -} diff --git a/c/src/tests/sptests/sp09/screen05.c b/c/src/tests/sptests/sp09/screen05.c deleted file mode 100644 index 00a57acd51..0000000000 --- a/c/src/tests/sptests/sp09/screen05.c +++ /dev/null @@ -1,170 +0,0 @@ -/* Screen5 - * - * This routine generates error screen 5 for test 9. - * - * Input parameters: NONE - * - * 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.com/license/LICENSE. - * - * $Id$ - */ - -#include "system.h" - -void Screen5() -{ - rtems_status_code status; - - status = rtems_semaphore_create( - 0, - 1, - RTEMS_DEFAULT_ATTRIBUTES, - RTEMS_NO_PRIORITY, - &Junk_id - ); - fatal_directive_status( - status, - RTEMS_INVALID_NAME, - "rtems_semaphore_create with illegal name" - ); - puts( "TA1 - rtems_semaphore_create - RTEMS_INVALID_NAME" ); - - status = rtems_semaphore_create( - Semaphore_name[ 1 ], - 1, - RTEMS_DEFAULT_ATTRIBUTES, - RTEMS_NO_PRIORITY, - &Semaphore_id[ 1 ] - ); - directive_failed( status, "rtems_semaphore_create" ); - puts( "TA1 - rtems_semaphore_create - 1 - RTEMS_SUCCESSFUL" ); - - status = rtems_semaphore_create( - Semaphore_name[ 2 ], - 1, - RTEMS_BINARY_SEMAPHORE | RTEMS_PRIORITY | RTEMS_INHERIT_PRIORITY, - RTEMS_NO_PRIORITY, - &Semaphore_id[ 2 ] - ); - directive_failed( status, "rtems_semaphore_create" ); - puts( "TA1 - rtems_semaphore_create - 2 - RTEMS_SUCCESSFUL" ); - - do { - status = rtems_semaphore_create( - Semaphore_name[ 3 ], - 1, - RTEMS_DEFAULT_ATTRIBUTES, - RTEMS_NO_PRIORITY, - &Junk_id - ); - } while (status == RTEMS_SUCCESSFUL); - - fatal_directive_status( - status, - RTEMS_TOO_MANY, - "rtems_semaphore_create of too many" - ); - puts( "TA1 - rtems_semaphore_create - 3 - RTEMS_TOO_MANY" ); - - status = rtems_semaphore_create( - Semaphore_name[ 1 ], - 1, - RTEMS_INHERIT_PRIORITY | RTEMS_BINARY_SEMAPHORE | RTEMS_FIFO, - RTEMS_NO_PRIORITY, - &Junk_id - ); - fatal_directive_status( - status, - RTEMS_NOT_DEFINED, - "rtems_semaphore_create of RTEMS_FIFO RTEMS_INHERIT_PRIORITY" - ); - puts( "TA1 - rtems_semaphore_create - RTEMS_NOT_DEFINED" ); - - status = rtems_semaphore_create( - Semaphore_name[ 1 ], - 1, - RTEMS_INHERIT_PRIORITY | RTEMS_COUNTING_SEMAPHORE | RTEMS_PRIORITY, - RTEMS_NO_PRIORITY, - &Junk_id - ); - fatal_directive_status( - status, - RTEMS_NOT_DEFINED, - "rtems_semaphore_create of RTEMS_COUNTING_SEMAPHORE RTEMS_INHERIT_PRIORITY" - ); - puts( "TA1 - rtems_semaphore_create - RTEMS_NOT_DEFINED" ); - - status = rtems_semaphore_create( - Semaphore_name[ 1 ], - 2, - RTEMS_BINARY_SEMAPHORE, - RTEMS_NO_PRIORITY, - &Junk_id - ); - fatal_directive_status( - status, - RTEMS_INVALID_NUMBER, - "rtems_semaphore_create of binary semaphore with count > 1" - ); - puts( "TA1 - rtems_semaphore_create - RTEMS_INVALID_NUMBER" ); - - /* - * The check for an object being global is only made if - * multiprocessing is enabled. - */ - -#if defined(RTEMS_MULTIPROCESSING) - status = rtems_semaphore_create( - Semaphore_name[ 3 ], - 1, - RTEMS_GLOBAL, - RTEMS_NO_PRIORITY, - &Junk_id - ); - fatal_directive_status( - status, - RTEMS_MP_NOT_CONFIGURED, - "rtems_semaphore_create of mp not configured" - ); -#endif - puts( "TA1 - rtems_semaphore_create - RTEMS_MP_NOT_CONFIGURED" ); - - status = rtems_semaphore_delete( 100 ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_semaphore_delete with illegal id" - ); - puts( "TA1 - rtems_semaphore_delete - unknown RTEMS_INVALID_ID" ); - - status = rtems_semaphore_delete( 0x010100 ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_semaphore_delete with local illegal id" - ); - puts( "TA1 - rtems_semaphore_delete - local RTEMS_INVALID_ID" ); - - status = rtems_semaphore_ident( 100, RTEMS_SEARCH_ALL_NODES, &Junk_id ); - fatal_directive_status( - status, - RTEMS_INVALID_NAME, - "rtems_semaphore_ident will illegal name (local)" - ); - puts( "TA1 - rtems_semaphore_ident - global RTEMS_INVALID_NAME" ); - - status = rtems_semaphore_ident( 100, 1, &Junk_id ); - fatal_directive_status( - status, - RTEMS_INVALID_NAME, - "rtems_semaphore_ident will illegal name (global)" - ); - puts( "TA1 - rtems_semaphore_ident - local RTEMS_INVALID_NAME" ); -} diff --git a/c/src/tests/sptests/sp09/screen06.c b/c/src/tests/sptests/sp09/screen06.c deleted file mode 100644 index 08b51dcdf4..0000000000 --- a/c/src/tests/sptests/sp09/screen06.c +++ /dev/null @@ -1,124 +0,0 @@ -/* Screen6 - * - * This routine generates error screen 6 for test 9. - * - * Input parameters: NONE - * - * 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.com/license/LICENSE. - * - * $Id$ - */ - -#include "system.h" - -void Screen6() -{ - rtems_status_code status; - - status = rtems_semaphore_obtain( - 100, - RTEMS_DEFAULT_OPTIONS, - RTEMS_NO_TIMEOUT - ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_semaphore_obtain with illegal id" - ); - puts( "TA1 - rtems_semaphore_obtain - RTEMS_INVALID_ID" ); - - status = rtems_semaphore_obtain( - Semaphore_id[ 1 ], - RTEMS_DEFAULT_OPTIONS, - RTEMS_NO_TIMEOUT - ); - directive_failed( status, "rtems_semaphore_obtain successful" ); - puts( "TA1 - rtems_semaphore_obtain - got sem 1 - RTEMS_SUCCESSFUL" ); - - status = rtems_semaphore_obtain( - Semaphore_id[ 1 ], - RTEMS_NO_WAIT, - RTEMS_NO_TIMEOUT - ); - fatal_directive_status( - status, - RTEMS_UNSATISFIED, - "rtems_semaphore_obtain not available" - ); - puts( "TA1 - rtems_semaphore_obtain - RTEMS_UNSATISFIED" ); - - puts( "TA1 - rtems_semaphore_obtain - timeout in 3 seconds" ); - status = rtems_semaphore_obtain( - Semaphore_id[ 1 ], - RTEMS_DEFAULT_OPTIONS, - 3 * TICKS_PER_SECOND - ); - fatal_directive_status( - status, - RTEMS_TIMEOUT, - "rtems_semaphore_obtain timeout" - ); - puts( "TA1 - rtems_semaphore_obtain - woke up with RTEMS_TIMEOUT" ); - - status = rtems_semaphore_release( Semaphore_id[ 2 ] ); - fatal_directive_status( - status, - RTEMS_NOT_OWNER_OF_RESOURCE, - "rtems_semaphore_release and not owner" - ); - puts( "TA1 - rtems_semaphore_release - RTEMS_NOT_OWNER_OF_RESOURCE" ); - - status = rtems_semaphore_release( 100 ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_semaphore_release with illegal id" - ); - puts( "TA1 - rtems_semaphore_release - RTEMS_INVALID_ID" ); - - puts( "TA1 - rtems_task_start - start TA2 - RTEMS_SUCCESSFUL" ); - status = rtems_task_start( Task_id[ 2 ], Task_2, 0 ); - directive_failed( status, "rtems_task_start of TA2" ); - - puts( "TA1 - rtems_task_wake_after - yield processor - RTEMS_SUCCESSFUL" ); - status = rtems_task_wake_after( RTEMS_YIELD_PROCESSOR ); - directive_failed( status, "rtems_task_wake_after (yield)" ); - - puts( "TA1 - rtems_semaphore_delete - delete sem 1 - RTEMS_SUCCESSFUL" ); - status = rtems_semaphore_delete( Semaphore_id[ 1 ] ); - directive_failed( status, "rtems_semaphore_delete of SM1" ); - - puts( "TA1 - rtems_semaphore_obtain - binary semaphore" ); - status = rtems_semaphore_obtain( - Semaphore_id[ 2 ], - RTEMS_DEFAULT_OPTIONS, - RTEMS_NO_TIMEOUT - ); - directive_failed( status, "rtems_semaphore_obtain"); - - puts( "TA1 - rtems_semaphore_delete - delete sem 2 - RTEMS_RESOURCE_IN_USE" ); - status = rtems_semaphore_delete( Semaphore_id[ 2 ] ); - fatal_directive_status( - status, - RTEMS_RESOURCE_IN_USE, - "rtems_semaphore_delete of SM2" - ); - - puts( "TA1 - rtems_task_wake_after - yield processor - RTEMS_SUCCESSFUL" ); - status = rtems_task_wake_after( RTEMS_YIELD_PROCESSOR ); - directive_failed( status, "rtems_task_wake_after (yield)" ); - - status = rtems_task_delete( Task_id[ 2 ] ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_task_delete after the task has been deleted" - ); -} diff --git a/c/src/tests/sptests/sp09/screen07.c b/c/src/tests/sptests/sp09/screen07.c deleted file mode 100644 index 2c9333b272..0000000000 --- a/c/src/tests/sptests/sp09/screen07.c +++ /dev/null @@ -1,208 +0,0 @@ -/* Screen7 - * - * This routine generates error screen 7 for test 9. - * - * Input parameters: NONE - * - * 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.com/license/LICENSE. - * - * $Id$ - */ - -#include "system.h" - -#define MESSAGE_SIZE (sizeof(long) * 4) - -void Screen7() -{ - long buffer[ 4 ]; - rtems_unsigned32 size; - rtems_unsigned32 count; - rtems_status_code status; - - status = rtems_message_queue_broadcast( 100, buffer, MESSAGE_SIZE, &count ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_message_queue_broadcast with illegal id" - ); - puts( "TA1 - rtems_message_queue_broadcast - RTEMS_INVALID_ID" ); - - status = rtems_message_queue_create( - 0, - 3, - MESSAGE_SIZE, - RTEMS_DEFAULT_ATTRIBUTES, - &Junk_id - ); - fatal_directive_status( - status, - RTEMS_INVALID_NAME, - "rtems_message_queue_create with illegal name" - ); - puts( "TA1 - rtems_message_queue_create - Q 1 - RTEMS_INVALID_NAME" ); - - /* - * The check for an object being global is only made if - * multiprocessing is enabled. - */ - -#if defined(RTEMS_MULTIPROCESSING) - status = rtems_message_queue_create( - Queue_name[ 1 ], - 1, - MESSAGE_SIZE, - RTEMS_GLOBAL, - &Junk_id - ); - fatal_directive_status( - status, - RTEMS_MP_NOT_CONFIGURED, - "rtems_message_queue_create of mp not configured" - ); -#endif - puts( "TA1 - rtems_message_queue_create - Q 1 - RTEMS_MP_NOT_CONFIGURED" ); - - status = rtems_message_queue_create( - Queue_name[ 1 ], - 2, - MESSAGE_SIZE, - RTEMS_DEFAULT_ATTRIBUTES, - &Queue_id[ 1 ] - ); - directive_failed( status, "rtems_message_queue_create successful" ); - puts( - "TA1 - rtems_message_queue_create - Q 1 - 2 DEEP - RTEMS_SUCCESSFUL" - ); - - status = rtems_message_queue_create( - Queue_name[ 2 ], - 1, - MESSAGE_SIZE, - RTEMS_DEFAULT_ATTRIBUTES, - &Junk_id - ); - fatal_directive_status( - status, - RTEMS_TOO_MANY, - "rtems_message_queue_create of too many" - ); - puts( "TA1 - rtems_message_queue_create - Q 2 - RTEMS_TOO_MANY" ); - - status = rtems_message_queue_delete( 100 ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_message_queue_create with illegal id" - ); - puts( "TA1 - rtems_message_queue_delete - unknown RTEMS_INVALID_ID" ); - - status = rtems_message_queue_delete( 0x10100 ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_message_queue_delete with local illegal id" - ); - puts( "TA1 - rtems_message_queue_delete - local RTEMS_INVALID_ID" ); - - status = rtems_message_queue_ident( 100, RTEMS_SEARCH_ALL_NODES, &Junk_id ); - fatal_directive_status( - status, - RTEMS_INVALID_NAME, - "rtems_message_queue_ident with illegal name" - ); - puts( "TA1 - rtems_message_queue_ident - RTEMS_INVALID_NAME" ); - - status = rtems_message_queue_get_number_pending( 100, &count ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_message_queue_get_number_pending with illegal id" - ); - puts( "TA1 - rtems_message_queue_get_number_pending - RTEMS_INVALID_ID" ); - - status = rtems_message_queue_flush( 100, &count ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_message_queue_flush with illegal id" - ); - puts( "TA1 - rtems_message_queue_flush - RTEMS_INVALID_ID" ); - - status = rtems_message_queue_receive( - 100, - (long (*)[4]) buffer, - &size, - RTEMS_DEFAULT_OPTIONS, - 0 - ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_message_queue_receive wit illegal id" - ); - puts( "TA1 - rtems_message_queue_receive - RTEMS_INVALID_ID" ); - - status = rtems_message_queue_receive( - Queue_id[ 1 ], - (long (*)[4]) buffer, - &size, - RTEMS_NO_WAIT, - RTEMS_NO_TIMEOUT - ); - fatal_directive_status( - status, - RTEMS_UNSATISFIED, - "rtems_message_queue_receive unsatisfied" - ); - puts( "TA1 - rtems_message_queue_receive - Q 1 - RTEMS_UNSATISFIED" ); - - puts( "TA1 - rtems_message_queue_receive - Q 1 - timeout in 3 seconds" ); - status = rtems_message_queue_receive( - Queue_id[ 1 ], - (long (*)[4]) buffer, - &size, - RTEMS_DEFAULT_OPTIONS, - 3 * TICKS_PER_SECOND - ); - fatal_directive_status( - status, - RTEMS_TIMEOUT, - "rtems_message_queue_receive 3 second timeout" - ); - - puts( - "TA1 - rtems_message_queue_receive - Q 1 - woke up with RTEMS_TIMEOUT" - ); - - status = rtems_message_queue_send( 100, buffer, MESSAGE_SIZE ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_message_queue_send with illegal id" - ); - puts( "TA1 - rtems_message_queue_send - RTEMS_INVALID_ID" ); - - status = rtems_message_queue_send( Queue_id[ 1 ], buffer, MESSAGE_SIZE ); - directive_failed( status, "rtems_message_queue_send" ); - puts( "TA1 - rtems_message_queue_send - BUFFER 1 TO Q 1 - RTEMS_SUCCESSFUL" ); - - status = rtems_message_queue_send( Queue_id[ 1 ], buffer, MESSAGE_SIZE ); - directive_failed( status, "rtems_message_queue_send" ); - puts( "TA1 - rtems_message_queue_send - BUFFER 2 TO Q 1 - RTEMS_SUCCESSFUL" ); - - status = rtems_message_queue_send( Queue_id[ 1 ], buffer, MESSAGE_SIZE ); - fatal_directive_status( - status, - RTEMS_TOO_MANY, - "rtems_message_queue_send too many to a limited queue" - ); - puts( "TA1 - rtems_message_queue_send - BUFFER 3 TO Q 1 - RTEMS_TOO_MANY" ); -} diff --git a/c/src/tests/sptests/sp09/screen08.c b/c/src/tests/sptests/sp09/screen08.c deleted file mode 100644 index 2f6efc6668..0000000000 --- a/c/src/tests/sptests/sp09/screen08.c +++ /dev/null @@ -1,129 +0,0 @@ -/* Screen8 - * - * This routine generates error screen 8 for test 9. - * - * Input parameters: NONE - * - * 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.com/license/LICENSE. - * - * $Id$ - */ - -#include "system.h" - -#define MESSAGE_SIZE (sizeof(long) * 4) - -void Screen8() -{ - long buffer[ 4 ]; - rtems_status_code status; - - status = rtems_message_queue_delete( Queue_id[ 1 ] ); - directive_failed( status, "rtems_message_queue_delete successful" ); - puts( "TA1 - rtems_message_queue_delete - Q 1 - RTEMS_SUCCESSFUL" ); - - status = rtems_message_queue_create( - Queue_name[ 1 ], - 2, - MESSAGE_SIZE, - RTEMS_DEFAULT_ATTRIBUTES, - &Queue_id[ 1 ] - ); - directive_failed( status, "rtems_message_queue_create successful" ); - puts( - "TA1 - rtems_message_queue_create - Q 1 - 2 DEEP - RTEMS_SUCCESSFUL" - ); - - status = rtems_message_queue_send( Queue_id[ 1 ], buffer, MESSAGE_SIZE ); - directive_failed( status, "rtems_message_queue_send successful" ); - puts( "TA1 - rtems_message_queue_send - BUFFER 1 TO Q 1 - RTEMS_SUCCESSFUL" ); - - status = rtems_message_queue_send( Queue_id[ 1 ], buffer, MESSAGE_SIZE ); - directive_failed( status, "rtems_message_queue_send successful" ); - puts( "TA1 - rtems_message_queue_send - BUFFER 2 TO Q 1 - RTEMS_SUCCESSFUL" ); - - status = rtems_message_queue_send( Queue_id[ 1 ], buffer, MESSAGE_SIZE ); - fatal_directive_status( - status, - RTEMS_TOO_MANY, - "rtems_message_queue_send too many to limited queue" - ); - puts( "TA1 - rtems_message_queue_send - BUFFER 3 TO Q 1 - RTEMS_TOO_MANY" ); - - status = rtems_message_queue_delete( Queue_id[ 1 ] ); - directive_failed( status, "rtems_message_queue_delete successful" ); - puts( "TA1 - rtems_message_queue_delete - Q 1 - RTEMS_SUCCESSFUL" ); - - status = rtems_message_queue_create( - Queue_name[ 1 ], - 3, - MESSAGE_SIZE, - RTEMS_DEFAULT_ATTRIBUTES, - &Queue_id[ 1 ] - ); - directive_failed( status, "rtems_message_queue_create successful" ); - puts( - "TA1 - rtems_message_queue_create - Q 1 - 3 DEEP - RTEMS_SUCCESSFUL" - ); - - status = rtems_message_queue_send( Queue_id[ 1 ], buffer, MESSAGE_SIZE ); - directive_failed( status, "rtems_message_queue_send successful" ); - puts( "TA1 - rtems_message_queue_send - BUFFER 1 TO Q 1 - RTEMS_SUCCESSFUL" ); - - status = rtems_message_queue_send( Queue_id[ 1 ], buffer, MESSAGE_SIZE ); - directive_failed( status, "rtems_message_queue_send successful" ); - puts( "TA1 - rtems_message_queue_send - BUFFER 2 TO Q 1 - RTEMS_SUCCESSFUL" ); - - status = rtems_message_queue_send( Queue_id[ 1 ], buffer, MESSAGE_SIZE ); - directive_failed( status, "rtems_message_queue_send successful" ); - puts( "TA1 - rtems_message_queue_send - BUFFER 3 TO Q 1 - RTEMS_SUCCESSFUL" ); - - status = rtems_message_queue_send( Queue_id[ 1 ], buffer, MESSAGE_SIZE ); - fatal_directive_status( - status, - RTEMS_TOO_MANY, - "rtems_message_queue_send too many to limited queue" - ); - puts( - "TA1 - rtems_message_queue_send - BUFFER 4 TO Q 1 - RTEMS_TOO_MANY" - ); - - status = rtems_message_queue_delete( Queue_id[ 1 ] ); - directive_failed( status, "rtems_message_queue_delete successful" ); - puts( "TA1 - rtems_message_queue_delete - Q 1 - RTEMS_SUCCESSFUL" ); - - status = rtems_message_queue_create( - Queue_name[ 1 ], - 3, - MESSAGE_SIZE, - RTEMS_DEFAULT_ATTRIBUTES, - &Queue_id[ 1 ] - ); - directive_failed( status, "rtems_message_queue_create successful" ); - puts( - "TA1 - rtems_message_queue_create - Q 1 - 3 DEEP - RTEMS_SUCCESSFUL" - ); - - puts( "TA1 - rtems_task_start - start TA3 - RTEMS_SUCCESSFUL" ); - status = rtems_task_start( Task_id[ 3 ], Task_3, 0 ); - directive_failed( status, "rtems_task_start of TA3" ); - - puts( "TA1 - rtems_task_wake_after - yield processor - RTEMS_SUCCESSFUL" ); - status = rtems_task_wake_after( RTEMS_YIELD_PROCESSOR ); - directive_failed( status, "rtems_task_wake_after (yield)" ); - - puts( "TA1 - rtems_message_queue_delete - delete Q 1 - RTEMS_SUCCESSFUL" ); - status = rtems_message_queue_delete( Queue_id[ 1 ] ); - directive_failed( status, "rtems_message_queue_delete successful" ); - - puts( "TA1 - rtems_task_wake_after - yield processor - RTEMS_SUCCESSFUL" ); - status = rtems_task_wake_after( RTEMS_YIELD_PROCESSOR ); - directive_failed( status, "rtems_task_wake_after (yield)" ); -} diff --git a/c/src/tests/sptests/sp09/screen09.c b/c/src/tests/sptests/sp09/screen09.c deleted file mode 100644 index 0e01acb3ef..0000000000 --- a/c/src/tests/sptests/sp09/screen09.c +++ /dev/null @@ -1,163 +0,0 @@ -/* Screen9 - * - * This routine generates error screen 9 for test 9. - * - * Input parameters: NONE - * - * 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.com/license/LICENSE. - * - * $Id$ - */ - -#include "system.h" - -void Screen9() -{ - void *converted; - rtems_status_code status; - rtems_isr_entry old_service_routine; - - status = rtems_interrupt_catch( - Service_routine, - ISR_INTERRUPT_MAXIMUM_VECTOR_NUMBER + 10, - &old_service_routine - ); - fatal_directive_status( - status, - RTEMS_INVALID_NUMBER, - "rtems_interrupt_catch with invalid vector" - ); - puts( "TA1 - rtems_interrupt_catch - RTEMS_INVALID_NUMBER" ); - -#if defined(_C3x) || defined(_C4x) - puts( "TA1 - rtems_interrupt_catch - bad handler RTEMS_INVALID_ADDRESS -- SKIPPED" ); -#else - status = rtems_interrupt_catch( NULL, 3, &old_service_routine ); - fatal_directive_status( - status, - RTEMS_INVALID_ADDRESS, - "rtems_interrupt_catch with invalid handler" - ); - puts( "TA1 - rtems_interrupt_catch - bad handler RTEMS_INVALID_ADDRESS" ); -#endif - -#if defined(_C3x) || defined(_C4x) - puts( "TA1 - rtems_interrupt_catch - old isr RTEMS_INVALID_ADDRESS - SKIPPED" ); -#else - status = rtems_interrupt_catch( Service_routine, 3, NULL ); - fatal_directive_status( - status, - RTEMS_INVALID_ADDRESS, - "rtems_interrupt_catch with invalid old isr pointer" - ); - puts( "TA1 - rtems_interrupt_catch - old isr RTEMS_INVALID_ADDRESS" ); -#endif - - status = rtems_signal_send( 100, RTEMS_SIGNAL_1 ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_signal_send with illegal id" - ); - puts( "TA1 - rtems_signal_send - RTEMS_INVALID_ID" ); - - status = rtems_signal_send( RTEMS_SELF, RTEMS_SIGNAL_16 ); - fatal_directive_status( - status, - RTEMS_NOT_DEFINED, - "rtems_signal_send with no handler" - ); - puts( "TA1 - rtems_signal_send - RTEMS_NOT_DEFINED" ); - - status = rtems_port_create( - 0, - Internal_port_area, - External_port_area, - sizeof( Internal_port_area ), - &Junk_id - ); - fatal_directive_status( - status, - RTEMS_INVALID_NAME, - "rtems_port_create with illegal name" - ); - puts( "TA1 - rtems_port_create - RTEMS_INVALID_NAME" ); - -#if defined(_C3x) || defined(_C4x) - puts( "TA1 - rtems_port_create - RTEMS_INVALID_ADDRESS - SKIPPED" ); -#else - status = rtems_port_create( - Port_name[ 1 ], - &((char *)Internal_port_area)[ 1 ], - External_port_area, - sizeof( Internal_port_area ), - &Junk_id - ); - fatal_directive_status( - status, - RTEMS_INVALID_ADDRESS, - "rtems_port_create with illegal address" - ); - puts( "TA1 - rtems_port_create - RTEMS_INVALID_ADDRESS" ); -#endif - - status = rtems_port_create( - Port_name[ 1 ], - Internal_port_area, - External_port_area, - sizeof( Internal_port_area ), - &Junk_id - ); - fatal_directive_status( - status, - RTEMS_TOO_MANY, - "rtems_port_create of too many" - ); - puts( "TA1 - rtems_port_create - RTEMS_TOO_MANY" ); - - status = rtems_port_delete( 0 ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_port_delete with illegal id" - ); - puts( "TA1 - rtems_port_delete - RTEMS_INVALID_ID" ); - - status = rtems_port_ident( 0, &Junk_id ); - fatal_directive_status( - status, - RTEMS_INVALID_NAME, - "rtems_port_ident with illegal name" - ); - puts( "TA1 - rtems_port_ident - RTEMS_INVALID_NAME" ); - - status = rtems_port_external_to_internal( - 100, - Internal_port_area, - &converted - ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_port_external_to_internal with illegal id" - ); - puts( "TA1 - rtems_port_external_to_internal - RTEMS_INVALID_ID" ); - status = rtems_port_internal_to_external( - 100, - Internal_port_area, - &converted - ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_port_internal_to_external with illegal id" - ); - puts( "TA1 - rtems_port_internal_to_external - RTEMS_INVALID_ID" ); -} diff --git a/c/src/tests/sptests/sp09/screen10.c b/c/src/tests/sptests/sp09/screen10.c deleted file mode 100644 index 9cc12fd25a..0000000000 --- a/c/src/tests/sptests/sp09/screen10.c +++ /dev/null @@ -1,163 +0,0 @@ -/* Screen10 - * - * This routine generates error screen 10 for test 9. - * - * Input parameters: NONE - * - * 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.com/license/LICENSE. - * - * $Id$ - */ - -#include "system.h" - -void Screen10() -{ - rtems_status_code status; - - status = rtems_rate_monotonic_create( 0, &Junk_id ); - fatal_directive_status( - status, - RTEMS_INVALID_NAME, - "rtems_rate_monotonic_create with illegal name" - ); - puts( "TA1 - rtems_rate_monotonic_create - RTEMS_INVALID_NAME" ); - - status = rtems_rate_monotonic_create( Period_name[ 1 ], &Period_id[ 1 ] ); - directive_failed( status, "rtems_rate_monotonic_create successful" ); - puts( "TA1 - rtems_rate_monotonic_create - RTEMS_SUCCESSFUL" ); - - status = rtems_rate_monotonic_create( Period_name[ 1 ], &Junk_id ); - fatal_directive_status( - status, - RTEMS_TOO_MANY, - "rtems_rate_monotonic_create of too many" - ); - puts( "TA1 - rtems_rate_monotonic_create - RTEMS_TOO_MANY" ); - - status = rtems_rate_monotonic_ident( 0, &Junk_id ); - fatal_directive_status( - status, - RTEMS_INVALID_NAME, - "rtems_rate_monotonic_ident with illegal name" - ); - puts( "TA1 - rtems_rate_monotonic_ident - RTEMS_INVALID_NAME" ); - - status = rtems_rate_monotonic_period( 100, 5 ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_rate_monotonic_period with illegal id" - ); - puts( "TA1 - rtems_rate_monotonic_period - unknown RTEMS_INVALID_ID" ); - - status = rtems_rate_monotonic_period( 0x10100, 5 ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_rate_monotonic_period with illegal id" - ); - puts( "TA1 - rtems_rate_monotonic_period - local RTEMS_INVALID_ID" ); - - status = rtems_rate_monotonic_period( Period_id[ 1 ], RTEMS_PERIOD_STATUS ); - fatal_directive_status( - status, - RTEMS_NOT_DEFINED, - "rtems_rate_monotonic_period status not defined" - ); - puts( - "TA1 - rtems_rate_monotonic_period(RTEMS_PERIOD_STATUS) - RTEMS_NOT_DEFINED" - ); - - status = rtems_rate_monotonic_period( Period_id[ 1 ], 100 ); - directive_failed( status, "rtems_rate_monotonic_period successful" ); - puts( "TA1 - rtems_rate_monotonic_period - 100 ticks - RTEMS_SUCCESSFUL" ); - - status = rtems_rate_monotonic_period( Period_id[ 1 ], RTEMS_PERIOD_STATUS ); - directive_failed( status, "rtems_rate_monotonic_period status" ); - puts( - "TA1 - rtems_rate_monotonic_period(RTEMS_PERIOD_STATUS) - RTEMS_SUCCESSFUL" - ); - - while ( FOREVER ) { - - status = rtems_rate_monotonic_period(Period_id[ 1 ], RTEMS_PERIOD_STATUS); - - if ( status == RTEMS_TIMEOUT ) break; - - directive_failed( - status, - "rtems_rate_monotonic_period waiting for timeout" - ); - } - puts( - "TA1 - rtems_rate_monotonic_period(RTEMS_PERIOD_STATUS) - RTEMS_TIMEOUT" - ); - - status = rtems_rate_monotonic_cancel( 100 ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_rate_monotonic_cancel with illegal id" - ); - puts( "TA1 - rtems_rate_monotonic_cancel - unknown RTEMS_INVALID_ID" ); - - status = rtems_rate_monotonic_cancel( 0x10100 ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_rate_monotonic_cancel will illegal id" - ); - puts( "TA1 - rtems_rate_monotonic_cancel - local RTEMS_INVALID_ID" ); - - status = rtems_rate_monotonic_cancel( Period_id[ 1 ] ); - directive_failed( status, "rtems_rate_monotonic_cancel" ); - puts( "TA1 - rtems_rate_monotonic_cancel - RTEMS_SUCCESSFUL" ); - - status = rtems_rate_monotonic_period( Period_id[ 1 ], 5 ); - directive_failed( status, "rtems_rate_monotonic_period restart" ); - - status = rtems_task_wake_after( 1 * TICKS_PER_SECOND ); - directive_failed( status, "rtems_task_wake_after" ); - - status = rtems_rate_monotonic_period( Period_id[ 1 ], 5 ); - fatal_directive_status( - status, - RTEMS_TIMEOUT, - "rtems_rate_monotonic_period" - ); - puts( "TA1 - rtems_rate_monotonic_period - 5 ticks - RTEMS_TIMEOUT" ); - - status = rtems_task_start( Task_id[ 4 ], Task_4, 0 ); - directive_failed( status, "rtems_task_start of TA4" ); - - puts( "TA1 - yielding to TA4" ); - status = rtems_task_wake_after( RTEMS_YIELD_PROCESSOR ); - - status = rtems_rate_monotonic_delete( 100 ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_rate_monotonic_delete with illegal id" - ); - puts( "TA1 - rtems_rate_monotonic_delete - unknown RTEMS_INVALID_ID" ); - - status = rtems_rate_monotonic_delete( 0x10100 ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_rate_monotonic_delete with illegal id" - ); - puts( "TA1 - rtems_rate_monotonic_delete - local RTEMS_INVALID_ID" ); - - status = rtems_rate_monotonic_delete( Period_id[ 1 ] ); - directive_failed( status, "rtems_rate_monotonic_delete" ); - puts( "TA1 - rtems_rate_monotonic_delete - RTEMS_SUCCESSFUL" ); -} diff --git a/c/src/tests/sptests/sp09/screen11.c b/c/src/tests/sptests/sp09/screen11.c deleted file mode 100644 index f9cbd5bbd3..0000000000 --- a/c/src/tests/sptests/sp09/screen11.c +++ /dev/null @@ -1,264 +0,0 @@ -/* Screen11 - * - * This routine generates error screen 11 for test 9. - * - * Input parameters: NONE - * - * 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.com/license/LICENSE. - * - * $Id$ - */ - -#include "system.h" - -void Screen11() -{ - void *buffer_address_1; - void *buffer_address_2; - void *buffer_address_3; - rtems_status_code status; - - status = rtems_partition_create( - 0, - Partition_good_area, - 128, - 40, - RTEMS_DEFAULT_ATTRIBUTES, - &Junk_id - ); - fatal_directive_status( - status, - RTEMS_INVALID_NAME, - "rtems_partition_create with illegal name" - ); - puts( "TA1 - rtems_partition_create - RTEMS_INVALID_NAME" ); - - status = rtems_partition_create( - Partition_name[ 1 ], - Partition_good_area, - 0, - 80, - RTEMS_DEFAULT_ATTRIBUTES, - &Junk_id - ); - fatal_directive_status( - status, - RTEMS_INVALID_SIZE, - "rtems_partition_create with illegal length" - ); - puts( "TA1 - rtems_partition_create - length - RTEMS_INVALID_SIZE" ); - - status = rtems_partition_create( - Partition_name[ 1 ], - Partition_good_area, - 128, - 0, - RTEMS_DEFAULT_ATTRIBUTES, - &Junk_id - ); - fatal_directive_status( - status, - RTEMS_INVALID_SIZE, - "rtems_partition_create with illegal buffer size" - ); - puts( "TA1 - rtems_partition_create - buffer size - RTEMS_INVALID_SIZE" ); - - status = rtems_partition_create( - Partition_name[ 1 ], - Partition_good_area, - 128, - 256, - RTEMS_DEFAULT_ATTRIBUTES, - &Junk_id - ); - fatal_directive_status( - status, - RTEMS_INVALID_SIZE, - "rtems_partition_create with buffer_size > length" - ); - puts( - "TA1 - rtems_partition_create - length < buffer size - RTEMS_INVALID_SIZE" - ); - - /* - * The check for an object being global is only made if - * multiprocessing is enabled. - */ - -#if defined(RTEMS_MULTIPROCESSING) - status = rtems_partition_create( - Partition_name[ 1 ], - Partition_good_area, - 128, - 64, - RTEMS_GLOBAL, - &Junk_id - ); - fatal_directive_status( - status, - RTEMS_MP_NOT_CONFIGURED, - "rtems_partition_create of global" - ); -#endif - puts( "TA1 - rtems_partition_create - RTEMS_MP_NOT_CONFIGURED" ); - -#if defined(_C3x) || defined(_C4x) - puts( "TA1 - rtems_partition_create - RTEMS_INVALID_ADDRESS - SKIPPED" ); -#else - status = rtems_partition_create( - Partition_name[ 1 ], - Partition_bad_area, - 128, - 64, - RTEMS_GLOBAL, - &Junk_id - ); - fatal_directive_status( - status, - RTEMS_INVALID_ADDRESS, - "rtems_partition_create with bad address" - ); - puts( "TA1 - rtems_partition_create - RTEMS_INVALID_ADDRESS" ); -#endif - -#if defined(_C3x) || defined(_C4x) - puts( "TA1 - rtems_partition_create - RTEMS_INVALID_SIZE - SKIPPED" ); -#else - status = rtems_partition_create( - Partition_name[ 1 ], - Partition_good_area, - 128, - 34, - RTEMS_DEFAULT_ATTRIBUTES, - &Junk_id - ); - fatal_directive_status( - status, - RTEMS_INVALID_SIZE, - "rtems_partition_create with unaligned buffer_size" - ); - puts( "TA1 - rtems_partition_create - RTEMS_INVALID_SIZE" ); -#endif - - status = rtems_partition_delete( 100 ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_partition_delete with illegal id" - ); - puts( "TA1 - rtems_partition_delete - unknown RTEMS_INVALID_ID" ); - - status = rtems_partition_delete( 0x10100 ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_partition_delete with illegal id" - ); - puts( "TA1 - rtems_partition_delete - local RTEMS_INVALID_ID" ); - - status = rtems_partition_get_buffer( 100, &buffer_address_1 ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_partition_get_buffer with illegal id" - ); - puts( "TA1 - rtems_partition_get_buffer - RTEMS_INVALID_ID" ); - - status = rtems_partition_ident( 0, RTEMS_SEARCH_ALL_NODES, &Junk_id ); - fatal_directive_status( - status, - RTEMS_INVALID_NAME, - "rtems_partition_ident with illegal name" - ); - puts( "TA1 - rtems_partition_ident - RTEMS_INVALID_NAME" ); - - status = rtems_partition_return_buffer( 100, buffer_address_1 ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_partition_return_buffer with illegal id" - ); - puts( "TA1 - rtems_partition_return_buffer - RTEMS_INVALID_ID" ); - - status = rtems_partition_create( - Partition_name[ 1 ], - Partition_good_area, - 128, - 64, - RTEMS_DEFAULT_ATTRIBUTES, - &Partition_id[ 1 ] - ); - directive_failed( status, "rtems_partition_create" ); - puts( "TA1 - rtems_partition_create - RTEMS_SUCCESSFUL" ); - - status = rtems_partition_create( - Partition_name[ 1 ], - Partition_good_area, - 128, - 32, - RTEMS_DEFAULT_ATTRIBUTES, - &Junk_id - ); - fatal_directive_status( - status, - RTEMS_TOO_MANY, - "rtems_partition_create of too many" - ); - puts( "TA1 - rtems_partition_create - RTEMS_TOO_MANY" ); - - status = rtems_partition_get_buffer( Partition_id[ 1 ], &buffer_address_1 ); - directive_failed( status, "rtems_partition_get_buffer"); - puts( "TA1 - rtems_partition_get_buffer - RTEMS_SUCCESSFUL" ); - - status = rtems_partition_get_buffer( Partition_id[ 1 ], &buffer_address_2 ); - directive_failed( status, "rtems_partition_get_buffer" ); - puts( "TA1 - rtems_partition_get_buffer - RTEMS_SUCCESSFUL" ); - - status = rtems_partition_get_buffer( Partition_id[ 1 ], &buffer_address_3 ); - fatal_directive_status( - status, - RTEMS_UNSATISFIED, - "rtems_partition_get_buffer unsatisfied" - ); - puts( "TA1 - rtems_partition_get_buffer - RTEMS_UNSATISFIED" ); - - status = rtems_partition_delete( Partition_id[ 1 ] ); - fatal_directive_status( - status, - RTEMS_RESOURCE_IN_USE, - "rtems_partition_delete with buffers in use" - ); - puts( "TA1 - rtems_partition_delete - RTEMS_RESOURCE_IN_USE" ); - - status = rtems_partition_return_buffer( - Partition_id[ 1 ], - Region_good_area /* NOTE: Region Memory */ - ); - fatal_directive_status( - status, - RTEMS_INVALID_ADDRESS, - "rtems_partition_return_buffer with buffer address out of partition" - ); - puts( - "TA1 - rtems_partition_return_buffer - RTEMS_INVALID_ADDRESS - out of range" - ); - - status = rtems_partition_return_buffer( - Partition_id[ 1 ], - &Partition_good_area[ 7 ] - ); - fatal_directive_status( - status, - RTEMS_INVALID_ADDRESS, - "rtems_partition_return_buffer with buffer address not on boundary" - ); - puts_nocr( "TA1 - rtems_partition_return_buffer - " ); - puts ( "RTEMS_INVALID_ADDRESS - not on boundary"); -} diff --git a/c/src/tests/sptests/sp09/screen12.c b/c/src/tests/sptests/sp09/screen12.c deleted file mode 100644 index 8b6e8231b3..0000000000 --- a/c/src/tests/sptests/sp09/screen12.c +++ /dev/null @@ -1,344 +0,0 @@ -/* Screen12 - * - * This routine generates error screen 12 for test 9. - * - * Input parameters: NONE - * - * 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.com/license/LICENSE. - * - * $Id$ - */ - -#include "system.h" - -void Screen12() -{ - void *segment_address_1; - void *segment_address_2; - void *segment_address_3; - rtems_unsigned32 offset; - rtems_unsigned32 good_front_flag; - rtems_unsigned32 good_back_flag; - rtems_status_code status; - - status = rtems_region_create( - 0, - Region_good_area, - 0x40, - 32, - RTEMS_DEFAULT_ATTRIBUTES, - &Junk_id - ); - fatal_directive_status( - status, - RTEMS_INVALID_NAME, - "rtems_region_create with illegal name" - ); - puts( "TA1 - rtems_region_create - RTEMS_INVALID_NAME" ); - -#if defined(_C3x) || defined(_C4x) - puts( "TA1 - rtems_region_create - RTEMS_INVALID_ADDRESS - SKIPPED" ); -#else - status = rtems_region_create( - Region_name[ 1 ], - Region_bad_area, - 0x40, - 32, - RTEMS_DEFAULT_ATTRIBUTES, - &Junk_id - ); - fatal_directive_status( - status, - RTEMS_INVALID_ADDRESS, - "rtems_region_create with illegal address" - ); - puts( "TA1 - rtems_region_create - RTEMS_INVALID_ADDRESS" ); -#endif - -#if defined(_C3x) || defined(_C4x) - puts( "TA1 - rtems_region_create - RTEMS_INVALID_SIZE - SKIPPED" ); -#else - status = rtems_region_create( - Region_name[ 1 ], - Region_good_area, - 0x40, - 34, - RTEMS_DEFAULT_ATTRIBUTES, - &Junk_id - ); - fatal_directive_status( - status, - RTEMS_INVALID_SIZE, - "rtems_region_create with illegal size" - ); - puts( "TA1 - rtems_region_create - RTEMS_INVALID_SIZE" ); -#endif - - status = rtems_region_create( - Region_name[ 1 ], - &Region_good_area[ REGION_START_OFFSET ], - REGION_LENGTH, - 0x40, - RTEMS_DEFAULT_ATTRIBUTES, - &Region_id[ 1 ] - ); - directive_failed( status, "rtems_region_create" ); - puts( "TA1 - rtems_region_create - RTEMS_SUCCESSFUL" ); - - status = rtems_region_create( - Region_name[ 1 ], - Region_good_area, - REGION_LENGTH, - 0x40, - RTEMS_DEFAULT_ATTRIBUTES, - &Junk_id - ); - fatal_directive_status( - status, - RTEMS_TOO_MANY, - "rtems_region_create of too many" - ); - puts( "TA1 - rtems_region_create - RTEMS_TOO_MANY" ); - - status = rtems_region_delete( 100 ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_region_delete with illegal id" - ); - puts( "TA1 - rtems_region_delete - unknown RTEMS_INVALID_ID" ); - - status = rtems_region_delete( 0x10100 ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_region_delete with illegal id" - ); - puts( "TA1 - rtems_region_delete - local RTEMS_INVALID_ID" ); - - status = rtems_region_ident( 0, &Junk_id ); - fatal_directive_status( - status, - RTEMS_INVALID_NAME, - "rtems_region_ident with illegal name" - ); - puts( "TA1 - rtems_region_ident - RTEMS_INVALID_NAME" ); - - status = rtems_region_get_segment( - 100, - 0x40, - RTEMS_DEFAULT_OPTIONS, - RTEMS_NO_TIMEOUT, - &segment_address_1 - ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_region_get_segment with illegal id" - ); - puts( "TA1 - rtems_region_get_segment - RTEMS_INVALID_ID" ); - - status = rtems_region_get_segment( - Region_id[ 1 ], - sizeof( Region_good_area ) * 2, - RTEMS_DEFAULT_OPTIONS, - RTEMS_NO_TIMEOUT, - &segment_address_1 - ); - fatal_directive_status( - status, - RTEMS_INVALID_SIZE, - "rtems_region_get_segment with illegal size" - ); - puts( "TA1 - rtems_region_get_segment - RTEMS_INVALID_SIZE" ); - - status = rtems_region_get_segment( - Region_id[ 1 ], - 384, - RTEMS_DEFAULT_OPTIONS, - RTEMS_NO_TIMEOUT, - &segment_address_1 - ); - directive_failed( status, "rtems_region_get_segment" ); - puts( "TA1 - rtems_region_get_segment - RTEMS_SUCCESSFUL" ); - - status = rtems_region_get_segment( - Region_id[ 1 ], - REGION_LENGTH / 2, - RTEMS_NO_WAIT, - RTEMS_NO_TIMEOUT, - &segment_address_2 - ); - fatal_directive_status( - status, - RTEMS_UNSATISFIED, - "rtems_region_get_segment unsatisfied" - ); - puts( "TA1 - rtems_region_get_segment - RTEMS_UNSATISFIED" ); - - puts( "TA1 - rtems_region_get_segment - timeout in 3 seconds" ); - status = rtems_region_get_segment( - Region_id[ 1 ], - 128, - RTEMS_DEFAULT_OPTIONS, - 3 * TICKS_PER_SECOND, - &segment_address_3 - ); - fatal_directive_status( - status, - RTEMS_TIMEOUT, - "rtems_region_get_segment timeout" - ); - puts( "TA1 - rtems_region_get_segment - woke up with RTEMS_TIMEOUT" ); - - status = rtems_region_delete( Region_id[ 1 ] ); - fatal_directive_status( - status, - RTEMS_RESOURCE_IN_USE, - "rtems_region_delete with buffers in use" - ); - puts( "TA1 - rtems_region_delete - RTEMS_RESOURCE_IN_USE" ); - - status = rtems_region_return_segment( 100, segment_address_1 ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_region_return_segment with illegal id" - ); - puts( "TA1 - rtems_region_return_segment - RTEMS_INVALID_ID" ); - - status = rtems_region_return_segment( Region_id[ 1 ], Region_good_area ); - fatal_directive_status( - status, - RTEMS_INVALID_ADDRESS, - "rtems_region_return_segment with illegal segment" - ); - puts( "TA1 - rtems_region_return_segment - RTEMS_INVALID_ADDRESS" ); - -/* - * The following generate internal heap errors. Thus this code - * is subject to change if the heap code changes. - */ - - puts( "TA1 - rtems_debug_disable - RTEMS_DEBUG_REGION" ); - rtems_debug_disable( RTEMS_DEBUG_REGION ); - -#if 0 - - offset = (segment_address_1 - (void *)Region_good_area) / 4; - -/* bad FRONT_FLAG error */ - - good_front_flag = Region_good_area[ offset - 1 ]; - Region_good_area[ offset - 1 ] = good_front_flag + 2; - - status = rtems_region_return_segment( Region_id[ 1 ], segment_address_1 ); - fatal_directive_status( - status, - RTEMS_INVALID_ADDRESS, - "rtems_region_return_segment with back_flag != front_flag" - ); - puts( "TA1 - rtems_region_return_segment - RTEMS_INVALID_ADDRESS" ); - - Region_good_area[ offset - 1 ] = good_front_flag; - -/* bad FRONT_FLAG error */ - - good_back_flag = Region_good_area[ offset - 2 ]; - Region_good_area[ offset - 2 ] = 1024; - - status = rtems_region_return_segment( Region_id[ 1 ], segment_address_1 ); - fatal_directive_status( - status, - RTEMS_INVALID_ADDRESS, - "rtems_region_return_segment with back_flag != front_flag" - ); - puts( "TA1 - rtems_region_return_segment - RTEMS_INVALID_ADDRESS" ); - - Region_good_area[ offset - 2 ] = good_back_flag; - -#else - offset = 0; - good_front_flag = 0; - good_back_flag = 0; - puts( "TA1 - rtems_region_return_segment - RTEMS_INVALID_ADDRESS - SKIPPED" ); - puts( "TA1 - rtems_region_return_segment - RTEMS_INVALID_ADDRESS - SKIPPED" ); -#endif - - puts( "TA1 - rtems_debug_enable - RTEMS_DEBUG_REGION" ); - rtems_debug_enable( RTEMS_DEBUG_REGION ); - - status = rtems_region_extend( - 100, - Region_good_area, - 128 - ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_region_extend with illegal id" - ); - puts( "TA1 - rtems_region_extend - RTEMS_INVALID_ID" ); - - status = rtems_region_extend( - Region_id[ 1 ], - &Region_good_area[ REGION_START_OFFSET + 16 ], - 128 - ); - fatal_directive_status( - status, - RTEMS_INVALID_ADDRESS, - "rtems_region_extend with illegal starting address" - ); - puts( "TA1 - rtems_region_extend - within heap - RTEMS_INVALID_ADDRESS" ); - - status = rtems_region_extend( - Region_id[ 1 ], - Region_bad_area, - 128 - ); - fatal_directive_status( - status, - RTEMS_NOT_IMPLEMENTED, - "rtems_region_extend with unsupported starting address" - ); - puts( - "TA1 - rtems_region_extend - non-contiguous lower - RTEMS_NOT_IMPLEMENTED" - ); - - status = rtems_region_extend( - Region_id[ 1 ], - &Region_good_area[ REGION_START_OFFSET - REGION_LENGTH ], - 128 - ); - fatal_directive_status( - status, - RTEMS_NOT_IMPLEMENTED, - "rtems_region_extend with unsupported starting address" - ); - puts( - "TA1 - rtems_region_extend - contiguous lower - RTEMS_NOT_IMPLEMENTED" - ); - - status = rtems_region_extend( - Region_id[ 1 ], - &Region_good_area[ REGION_START_OFFSET + REGION_LENGTH + 16 ], - 128 - ); - fatal_directive_status( - status, - RTEMS_NOT_IMPLEMENTED, - "rtems_region_extend with unsupported starting address" - ); - puts( - "TA1 - rtems_region_extend - non-contiguous higher - RTEMS_NOT_IMPLEMENTED" - ); - -} diff --git a/c/src/tests/sptests/sp09/screen13.c b/c/src/tests/sptests/sp09/screen13.c deleted file mode 100644 index 1f57cbce28..0000000000 --- a/c/src/tests/sptests/sp09/screen13.c +++ /dev/null @@ -1,113 +0,0 @@ -/* Screen13 - * - * This routine generates error screen 13 for test 9. - * - * Input parameters: NONE - * - * 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.com/license/LICENSE. - * - * $Id$ - */ - -#include "system.h" - -void Screen13() -{ - rtems_time_of_day time; - rtems_status_code status; - - status = rtems_io_close( 0xffff, 0x0000, NULL); - fatal_directive_status( - status, - RTEMS_INVALID_NUMBER, - "rtems_io_close with bad major number" - ); - puts( "TA1 - rtems_io_close - RTEMS_INVALID_NUMBER" ); - status = rtems_io_control( 0xffff, 0x00000, NULL); - fatal_directive_status( - status, - RTEMS_INVALID_NUMBER, - "rtems_io_close with bad major number" - ); - puts( "TA1 - rtems_io_control - RTEMS_INVALID_NUMBER" ); - status = rtems_io_initialize( 0xffff, 0x00000, NULL); - fatal_directive_status( - status, - RTEMS_INVALID_NUMBER, - "rtems_io_initialize with bad major number" - ); - puts( "TA1 - rtems_io_initialize - RTEMS_INVALID_NUMBER" ); - status = rtems_io_open( 0xffff, 0x00000, NULL); - fatal_directive_status( - status, - RTEMS_INVALID_NUMBER, - "rtems_io_open with bad major number" - ); - puts( "TA1 - rtems_io_open - RTEMS_INVALID_NUMBER" ); - status = rtems_io_read( 0xffff, 0x00000, NULL); - fatal_directive_status( - status, - RTEMS_INVALID_NUMBER, - "rtems_io_read with bad major number" - ); - puts( "TA1 - rtems_io_read - RTEMS_INVALID_NUMBER" ); - status = rtems_io_write( 0xffff, 0x0ffff, NULL); - fatal_directive_status( - status, - RTEMS_INVALID_NUMBER, - "rtems_io_write with bad major number" - ); - puts( "TA1 - rtems_io_write - RTEMS_INVALID_NUMBER" ); - - build_time( &time, 12, 31, 2000, 23, 59, 59, 0 ); - status = rtems_clock_set( &time ); - directive_failed( status, "rtems_clock_set" ); - print_time( "TA1 - rtems_clock_set - ", &time, " - RTEMS_SUCCESSFUL\n" ); - status = rtems_task_wake_after( 1 * TICKS_PER_SECOND ); - status = rtems_clock_get( RTEMS_CLOCK_GET_TOD, &time ); - directive_failed( status, "rtems_clock_set" ); - print_time( "TA1 - rtems_clock_get - ", &time, " - RTEMS_SUCCESSFUL\n" ); - - build_time( &time, 12, 31, 1999, 23, 59, 59, 0 ); - status = rtems_clock_set( &time ); - directive_failed( status, "rtems_clock_set" ); - print_time( "TA1 - rtems_clock_set - ", &time, " - RTEMS_SUCCESSFUL\n" ); - status = rtems_task_wake_after( 1 * TICKS_PER_SECOND ); - status = rtems_clock_get( RTEMS_CLOCK_GET_TOD, &time ); - directive_failed( status, "rtems_clock_set" ); - print_time( "TA1 - rtems_clock_get - ", &time, " - RTEMS_SUCCESSFUL\n" ); - - build_time( &time, 12, 31, 2100, 23, 59, 59, 0 ); - status = rtems_clock_set( &time ); - directive_failed( status, "rtems_clock_set" ); - print_time( "TA1 - rtems_clock_set - ", &time, " - RTEMS_SUCCESSFUL\n" ); - status = rtems_task_wake_after( 1 * TICKS_PER_SECOND ); - status = rtems_clock_get( RTEMS_CLOCK_GET_TOD, &time ); - directive_failed( status, "rtems_clock_set" ); - print_time( "TA1 - rtems_clock_get - ", &time, " - RTEMS_SUCCESSFUL\n" ); - - build_time( &time, 12, 31, 2099, 23, 59, 59, 0 ); - status = rtems_clock_set( &time ); - directive_failed( status, "rtems_clock_set" ); - print_time( "TA1 - rtems_clock_set - ", &time, " - RTEMS_SUCCESSFUL\n" ); - status = rtems_task_wake_after( 1 * TICKS_PER_SECOND ); - status = rtems_clock_get( RTEMS_CLOCK_GET_TOD, &time ); - directive_failed( status, "rtems_clock_set" ); - print_time( "TA1 - rtems_clock_get - ", &time, " - RTEMS_SUCCESSFUL\n" ); - - build_time( &time, 12, 31, 1991, 23, 59, 59, 0 ); - status = rtems_clock_set( &time ); - directive_failed( status, "rtems_clock_set" ); - print_time( "TA1 - rtems_clock_set - ", &time, " - RTEMS_SUCCESSFUL\n" ); - status = rtems_task_wake_after( 1 * TICKS_PER_SECOND ); - status = rtems_clock_get( RTEMS_CLOCK_GET_TOD, &time ); - directive_failed( status, "rtems_clock_set" ); - print_time( "TA1 - rtems_clock_get - ", &time, " - RTEMS_SUCCESSFUL\n" ); -} diff --git a/c/src/tests/sptests/sp09/screen14.c b/c/src/tests/sptests/sp09/screen14.c deleted file mode 100644 index 2dec42e8c2..0000000000 --- a/c/src/tests/sptests/sp09/screen14.c +++ /dev/null @@ -1,245 +0,0 @@ -/* Screen14 - * - * This routine generates error screen 14 for test 9. - * - * Input parameters: NONE - * - * 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.com/license/LICENSE. - * - * $Id$ - */ - -#include "system.h" - -void Screen14() -{ - rtems_status_code status; - rtems_time_of_day time; - - status = rtems_timer_create( 0, &Junk_id ); - fatal_directive_status( - status, - RTEMS_INVALID_NAME, - "rtems_timer_create with illegal name" - ); - puts( "TA1 - rtems_timer_create - RTEMS_INVALID_NAME" ); - - status = rtems_timer_create( Timer_name[ 1 ], &Timer_id[ 1 ] ); - directive_failed( status, "rtems_timer_create" ); - puts( "TA1 - rtems_timer_create - 1 - RTEMS_SUCCESSFUL" ); - - status = rtems_timer_create( 2, &Junk_id ); - fatal_directive_status( - status, - RTEMS_TOO_MANY, - "rtems_timer_create for too many" - ); - puts( "TA1 - rtems_timer_create - 2 - RTEMS_TOO_MANY" ); - - status = rtems_timer_delete( 100 ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_timer_delete with illegal id" - ); - puts( "TA1 - rtems_timer_delete - local RTEMS_INVALID_ID" ); - - status = rtems_timer_delete( 0x010100 ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_timer_delete with illegal id" - ); - puts( "TA1 - rtems_timer_delete - global RTEMS_INVALID_ID" ); - - status = rtems_timer_ident( 0, &Junk_id ); - fatal_directive_status( - status, - RTEMS_INVALID_NAME, - "rtems_timer_ident with illegal name" - ); - puts( "TA1 - rtems_timer_ident - RTEMS_INVALID_NAME" ); - - status = rtems_timer_cancel( 0x010100 ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_timer_cancel with illegal id" - ); - puts( "TA1 - rtems_timer_cancel - RTEMS_INVALID_ID" ); - - status = rtems_timer_reset( 0x010100 ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_timer_reset with illegal id" - ); - puts( "TA1 - rtems_timer_reset - RTEMS_INVALID_ID" ); - - status = rtems_timer_reset( Timer_id[ 1 ] ); - fatal_directive_status( - status, - RTEMS_NOT_DEFINED, - "rtems_timer_reset before initiated" - ); - puts( "TA1 - rtems_timer_reset - RTEMS_NOT_DEFINED" ); - - status = rtems_timer_fire_after( - 0x010100, - 5 * TICKS_PER_SECOND, - Delayed_routine, - NULL - ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_timer_fire_after illegal id" - ); - puts( "TA1 - rtems_timer_fire_after - RTEMS_INVALID_ID" ); - - build_time( &time, 12, 31, 1994, 9, 0, 0, 0 ); - status = rtems_timer_fire_when( 0x010100, &time, Delayed_routine, NULL ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_timer_fire_when with illegal id" - ); - puts( "TA1 - rtems_timer_fire_when - RTEMS_INVALID_ID" ); - - status = rtems_timer_fire_after( Timer_id[ 1 ], 0, Delayed_routine, NULL ); - fatal_directive_status( - status, - RTEMS_INVALID_NUMBER, - "rtems_timer_fire_after with 0 ticks" - ); - puts( "TA1 - rtems_timer_fire_after - RTEMS_INVALID_NUMBER" ); - - build_time( &time, 2, 5, 1987, 8, 30, 45, 0 ); - status = rtems_timer_fire_when( Timer_id[ 1 ], &time, Delayed_routine, NULL ); - fatal_directive_status( - status, - RTEMS_INVALID_CLOCK, - "rtems_timer_fire_when with illegal time" - ); - print_time( - "TA1 - rtems_timer_fire_when - ", - &time, - " - RTEMS_INVALID_CLOCK\n" - ); - - status = rtems_clock_get( RTEMS_CLOCK_GET_TOD, &time ); - directive_failed( status, "rtems_clock_set" ); - print_time( "TA1 - rtems_clock_get - ", &time, "\n" ); - - build_time( &time, 2, 5, 1990, 8, 30, 45, 0 ); - status = rtems_timer_fire_when( Timer_id[ 1 ], &time, Delayed_routine, NULL ); - fatal_directive_status( - status, - RTEMS_INVALID_CLOCK, - "rtems_timer_fire_when before current time" - ); - print_time( - "TA1 - rtems_timer_fire_when - ", - &time, - " - before RTEMS_INVALID_CLOCK\n" - ); - -/* timer server interface routines */ - - status = rtems_timer_server_fire_after( 0, 5, NULL, NULL ); - fatal_directive_status( - status, - RTEMS_INCORRECT_STATE, - "rtems_timer_server_fire_after incorrect state" - ); - puts( "TA1 - rtems_timer_server_fire_after - RTEMS_INCORRECT_STATE" ); - - status = rtems_timer_server_fire_when( 0, &time, NULL, NULL ); - fatal_directive_status( - status, - RTEMS_INCORRECT_STATE, - "rtems_timer_server_fire_when incorrect state" - ); - puts( "TA1 - rtems_timer_server_fire_when - RTEMS_INCORRECT_STATE" ); - - status = - rtems_timer_initiate_server( 0, 0, 0 ); - fatal_directive_status( - status, - RTEMS_INVALID_PRIORITY, - "rtems_timer_initiate_server invalid priority" - ); - puts( "TA1 - rtems_timer_initiate_server - RTEMS_INVALID_PRIORITY" ); - - status = - rtems_timer_initiate_server( RTEMS_TIMER_SERVER_DEFAULT_PRIORITY, 0, 0 ); - directive_failed( status, "rtems_timer_initiate_server" ); - puts( "TA1 - rtems_timer_initiate_server" ); - - status = rtems_timer_server_fire_after( - 0x010100, - 5 * TICKS_PER_SECOND, - Delayed_routine, - NULL - ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_timer_server_fire_after illegal id" - ); - puts( "TA1 - rtems_timer_server_fire_after - RTEMS_INVALID_ID" ); - - build_time( &time, 12, 31, 1994, 9, 0, 0, 0 ); - status = rtems_timer_server_fire_when( 0x010100, &time, Delayed_routine, NULL ); - fatal_directive_status( - status, - RTEMS_INVALID_ID, - "rtems_timer_server_fire_when with illegal id" - ); - puts( "TA1 - rtems_timer_server_fire_when - RTEMS_INVALID_ID" ); - - status = rtems_timer_server_fire_after( Timer_id[ 1 ], 0, Delayed_routine, NULL ); - fatal_directive_status( - status, - RTEMS_INVALID_NUMBER, - "rtems_timer_server_fire_after with 0 ticks" - ); - puts( "TA1 - rtems_timer_server_fire_after - RTEMS_INVALID_NUMBER" ); - - build_time( &time, 2, 5, 1987, 8, 30, 45, 0 ); - status = rtems_timer_server_fire_when( Timer_id[ 1 ], &time, Delayed_routine, NULL ); - fatal_directive_status( - status, - RTEMS_INVALID_CLOCK, - "rtems_timer_server_fire_when with illegal time" - ); - print_time( - "TA1 - rtems_timer_server_fire_when - ", - &time, - " - RTEMS_INVALID_CLOCK\n" - ); - - status = rtems_clock_get( RTEMS_CLOCK_GET_TOD, &time ); - directive_failed( status, "rtems_clock_set" ); - print_time( "TA1 - rtems_clock_get - ", &time, "\n" ); - - build_time( &time, 2, 5, 1990, 8, 30, 45, 0 ); - status = rtems_timer_server_fire_when( Timer_id[ 1 ], &time, Delayed_routine, NULL ); - fatal_directive_status( - status, - RTEMS_INVALID_CLOCK, - "rtems_timer_server_fire_when before current time" - ); - print_time( - "TA1 - rtems_timer_server_fire_when - ", - &time, - " - before RTEMS_INVALID_CLOCK\n" - ); -} diff --git a/c/src/tests/sptests/sp09/sp09.doc b/c/src/tests/sptests/sp09/sp09.doc deleted file mode 100644 index f7bee594a5..0000000000 --- a/c/src/tests/sptests/sp09/sp09.doc +++ /dev/null @@ -1,35 +0,0 @@ -# -# $Id$ -# -# 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.com/license/LICENSE. -# - - -This file describes the directives and concepts tested by this test set. - -test set name: test9 - -directives: - ex_init, ex_start, tm_tick, i_return, - t_create,t_delete, t_getreg, t_ident, t_restart, t_resume, t_setpri, - t_setreg, t_start, t_suspend, tm_delete, tm_get, - tm_set, tm_wkafter, tm_wkwhen, ev_receive, ev_send, sm_create, sm_delete, - sm_ident, sm_p, sm_v, q_broadcast, q_create, q_delete, q_ident, q_receive, - q_send, q_urgent, as_catch, as_send, as_return, rn_create, rn_delete, - rn_getseg, rn_ident, rn_retseg, pt_create, pt_delete, pt_getbug, pt_ident, - pt_retbuf, de_close, de_cntrl, de_init, de_open, de_read, de_write - -concepts: - - a. Verifies all error codes returned by the executive in single - processor configurations. - - b. Verifies error conditions in the following kernel routines or macros: - _Ck_date_time, _Expired, _Q_submit, _Get_mnodes, _Get_node, - _Free_mem, _Get_mem, _Valid_block, _Set_tcb, _Set_resource, - _In_range, _On_boundary diff --git a/c/src/tests/sptests/sp09/sp09.scn b/c/src/tests/sptests/sp09/sp09.scn deleted file mode 100644 index 1f00519188..0000000000 --- a/c/src/tests/sptests/sp09/sp09.scn +++ /dev/null @@ -1,261 +0,0 @@ -*** TEST 9 *** -INIT - rtems_task_create - RTEMS_INVALID_SIZE -- NOT CHECKED -INIT - rtems_task_create - RTEMS_INVALID_PRIORITY -INIT - rtems_task_restart - RTEMS_INCORRECT_STATE -TA1 - rtems_task_delete - RTEMS_INVALID_ID -TA1 - rtems_task_get_note - RTEMS_INVALID_NUMBER -TA1 - rtems_task_get_note - RTEMS_INVALID_ID -TA1 - rtems_task_ident - current task RTEMS_SUCCESSFUL -TA1 - rtems_task_ident - global RTEMS_INVALID_NAME -TA1 - rtems_task_ident - local RTEMS_INVALID_NAME -TA1 - rtems_task_ident - RTEMS_INVALID_NODE -TA1 - rtems_task_restart - RTEMS_INVALID_ID -TA1 - rtems_task_resume - RTEMS_INVALID_ID -TA1 - rtems_task_resume - RTEMS_INCORRECT_STATE -TA1 - rtems_task_set_priority - RTEMS_INVALID_PRIORITY -TA1 - rtems_task_set_priority - RTEMS_INVALID_ID -TA1 - rtems_task_set_note - RTEMS_INVALID_NUMBER -TA1 - rtems_task_set_note - RTEMS_INVALID_ID -TA1 - rtems_task_start - RTEMS_INVALID_ID -TA1 - rtems_task_start - RTEMS_INCORRECT_STATE -TA1 - rtems_task_suspend - RTEMS_INVALID_ID -<pause - screen 2> -TA1 - rtems_clock_get - RTEMS_NOT_DEFINED -TA1 - rtems_task_wake_when - RTEMS_NOT_DEFINED -TA1 - rtems_timer_fire_when - RTEMS_NOT_DEFINED -TA1 - rtems_clock_set - 08:30:45 02/05/1987 - RTEMS_INVALID_CLOCK -TA1 - rtems_clock_set - 08:30:45 15/05/1988 - RTEMS_INVALID_CLOCK -TA1 - rtems_clock_set - 08:30:45 02/32/1988 - RTEMS_INVALID_CLOCK -TA1 - rtems_clock_set - 25:30:45 02/05/1988 - RTEMS_INVALID_CLOCK -TA1 - rtems_clock_set - 08:61:45 02/05/1988 - RTEMS_INVALID_CLOCK -TA1 - rtems_clock_set - 08:30:61 02/05/1988 - RTEMS_INVALID_CLOCK -TA1 - rtems_clock_set - 08:30:45 02/05/1988 - RTEMS_INVALID_CLOCK -TA1 - rtems_clock_set - 08:30:45 02/05/1988 - RTEMS_SUCCESSFUL -TA1 - rtems_task_wake_when - TICKINVALID - sleep about 3 seconds -TA1 - rtems_task_wake_when - TICKINVALID - woke up RTEMS_SUCCESSFUL -TA1 - rtems_task_wake_when - 08:30:48 02/05/1961 - RTEMS_INVALID_CLOCK -TA1 - rtems_task_wake_when - 25:30:48 02/05/1988 - RTEMS_INVALID_CLOCK -TA1 - current time - 08:30:51 02/05/1988 -TA1 - rtems_task_wake_when - 08:30:51 01/05/1988 - RTEMS_INVALID_CLOCK -<pause - screen 3> -TA1 - rtems_task_create - RTEMS_INVALID_NAME -TA1 - rtems_task_create - stack size - RTEMS_UNSATISFIED -TA1 - rtems_task_create - TA2 created - RTEMS_SUCCESSFUL -TA1 - rtems_task_suspend - suspend TA2 - RTEMS_SUCCESSFUL -TA1 - rtems_task_suspend - suspend TA2 - RTEMS_ALREADY_SUSPENDED -TA1 - rtems_task_resume - TA2 resumed - RTEMS_SUCCESSFUL -TA1 - rtems_task_create - TA3 created - RTEMS_SUCCESSFUL -TA1 - rtems_task_create - 4 created - RTEMS_SUCCESSFUL -TA1 - rtems_task_create - 5 created - RTEMS_SUCCESSFUL -TA1 - rtems_task_create - 6 created - RTEMS_SUCCESSFUL -TA1 - rtems_task_create - 7 created - RTEMS_SUCCESSFUL -TA1 - rtems_task_create - 8 created - RTEMS_SUCCESSFUL -TA1 - rtems_task_create - 9 created - RTEMS_SUCCESSFUL -TA1 - rtems_task_create - 10 created - RTEMS_SUCCESSFUL -TA1 - rtems_task_create - 11 - RTEMS_TOO_MANY -TA1 - rtems_task_create - RTEMS_MP_NOT_CONFIGURED -<pause - screen 4> -TA1 - rtems_event_receive - RTEMS_UNSATISFIED ( all conditions ) -TA1 - rtems_event_receive - RTEMS_UNSATISFIED ( any condition ) -TA1 - rtems_event_receive - timeout in 3 seconds -TA1 - rtems_event_receive - woke up with RTEMS_TIMEOUT -TA1 - rtems_event_send - RTEMS_INVALID_ID -TA1 - rtems_task_wake_after - sleep 1 second - RTEMS_SUCCESSFUL -TA1 - rtems_clock_set - 08:30:45 02/05/1988 - RTEMS_SUCCESSFUL -<pause - screen 5> -TA1 - rtems_semaphore_create - RTEMS_INVALID_NAME -TA1 - rtems_semaphore_create - 1 - RTEMS_SUCCESSFUL -TA1 - rtems_semaphore_create - 2 - RTEMS_SUCCESSFUL -TA1 - rtems_semaphore_create - 3 - RTEMS_TOO_MANY -TA1 - rtems_semaphore_create - RTEMS_NOT_DEFINED -TA1 - rtems_semaphore_create - RTEMS_NOT_DEFINED -TA1 - rtems_semaphore_create - RTEMS_INVALID_NUMBER -TA1 - rtems_semaphore_create - RTEMS_MP_NOT_CONFIGURED -TA1 - rtems_semaphore_delete - unknown RTEMS_INVALID_ID -TA1 - rtems_semaphore_delete - local RTEMS_INVALID_ID -TA1 - rtems_semaphore_ident - global RTEMS_INVALID_NAME -TA1 - rtems_semaphore_ident - local RTEMS_INVALID_NAME -<pause - screen 6> -TA1 - rtems_semaphore_obtain - RTEMS_INVALID_ID -TA1 - rtems_semaphore_obtain - got sem 1 - RTEMS_SUCCESSFUL -TA1 - rtems_semaphore_obtain - RTEMS_UNSATISFIED -TA1 - rtems_semaphore_obtain - timeout in 3 seconds -TA1 - rtems_semaphore_obtain - woke up with RTEMS_TIMEOUT -TA1 - rtems_semaphore_release - RTEMS_NOT_OWNER_OF_RESOURCE -TA1 - rtems_semaphore_release - RTEMS_INVALID_ID -TA1 - rtems_task_start - start TA2 - RTEMS_SUCCESSFUL -TA1 - rtems_task_wake_after - yield processor - RTEMS_SUCCESSFUL -TA2 - rtems_semaphore_obtain - sem 1 - RTEMS_WAIT FOREVER -TA1 - rtems_semaphore_delete - delete sem 1 - RTEMS_SUCCESSFUL -TA1 - rtems_semaphore_obtain - binary semaphore -TA1 - rtems_semaphore_delete - delete sem 2 - RTEMS_RESOURCE_IN_USE -TA1 - rtems_task_wake_after - yield processor - RTEMS_SUCCESSFUL -TA2 - rtems_semaphore_obtain - woke up with RTEMS_OBJECT_WAS_DELETED -TA2 - rtems_task_delete - delete self - RTEMS_SUCCESSFUL -<pause - screen 7> -TA1 - rtems_message_queue_broadcast - RTEMS_INVALID_ID -TA1 - rtems_message_queue_create - Q 1 - RTEMS_INVALID_NAME -TA1 - rtems_message_queue_create - Q 1 - RTEMS_MP_NOT_CONFIGURED -TA1 - rtems_message_queue_create - Q 1 - 2 DEEP - RTEMS_SUCCESSFUL -TA1 - rtems_message_queue_create - Q 2 - RTEMS_TOO_MANY -TA1 - rtems_message_queue_delete - unknown RTEMS_INVALID_ID -TA1 - rtems_message_queue_delete - local RTEMS_INVALID_ID -TA1 - rtems_message_queue_ident - RTEMS_INVALID_NAME -TA1 - rtems_message_queue_get_number_pending - RTEMS_INVALID_ID -TA1 - rtems_message_queue_flush - RTEMS_INVALID_ID -TA1 - rtems_message_queue_receive - RTEMS_INVALID_ID -TA1 - rtems_message_queue_receive - Q 1 - RTEMS_UNSATISFIED -TA1 - rtems_message_queue_receive - Q 1 - timeout in 3 seconds -TA1 - rtems_message_queue_receive - Q 1 - woke up with RTEMS_TIMEOUT -TA1 - rtems_message_queue_send - RTEMS_INVALID_ID -TA1 - rtems_message_queue_send - BUFFER 1 TO Q 1 - RTEMS_SUCCESSFUL -TA1 - rtems_message_queue_send - BUFFER 2 TO Q 1 - RTEMS_SUCCESSFUL -TA1 - rtems_message_queue_send - BUFFER 3 TO Q 1 - RTEMS_TOO_MANY -<pause - screen 8> -TA1 - rtems_message_queue_delete - Q 1 - RTEMS_SUCCESSFUL -TA1 - rtems_message_queue_create - Q 1 - 2 DEEP - RTEMS_SUCCESSFUL -TA1 - rtems_message_queue_send - BUFFER 1 TO Q 1 - RTEMS_SUCCESSFUL -TA1 - rtems_message_queue_send - BUFFER 2 TO Q 1 - RTEMS_SUCCESSFUL -TA1 - rtems_message_queue_send - BUFFER 3 TO Q 1 - RTEMS_TOO_MANY -TA1 - rtems_message_queue_delete - Q 1 - RTEMS_SUCCESSFUL -TA1 - rtems_message_queue_create - Q 1 - 3 DEEP - RTEMS_SUCCESSFUL -TA1 - rtems_message_queue_send - BUFFER 1 TO Q 1 - RTEMS_SUCCESSFUL -TA1 - rtems_message_queue_send - BUFFER 2 TO Q 1 - RTEMS_SUCCESSFUL -TA1 - rtems_message_queue_send - BUFFER 3 TO Q 1 - RTEMS_SUCCESSFUL -TA1 - rtems_message_queue_send - BUFFER 4 TO Q 1 - RTEMS_TOO_MANY -TA1 - rtems_message_queue_delete - Q 1 - RTEMS_SUCCESSFUL -TA1 - rtems_message_queue_create - Q 1 - 3 DEEP - RTEMS_SUCCESSFUL -TA1 - rtems_task_start - start TA3 - RTEMS_SUCCESSFUL -TA1 - rtems_task_wake_after - yield processor - RTEMS_SUCCESSFUL -TA3 - rtems_message_queue_receive - Q 1 - RTEMS_WAIT FOREVER -TA1 - rtems_message_queue_delete - delete Q 1 - RTEMS_SUCCESSFUL -TA1 - rtems_task_wake_after - yield processor - RTEMS_SUCCESSFUL -TA3 - rtems_message_queue_receive - woke up with RTEMS_OBJECT_WAS_DELETED -TA3 - rtems_task_delete - delete self - RTEMS_SUCCESSFUL -<pause - screen 9> -TA1 - rtems_interrupt_catch - RTEMS_INVALID_NUMBER -TA1 - rtems_interrupt_catch - bad handler RTEMS_INVALID_ADDRESS -TA1 - rtems_interrupt_catch - old isr RTEMS_INVALID_ADDRESS -TA1 - rtems_signal_send - RTEMS_INVALID_ID -TA1 - rtems_signal_send - RTEMS_NOT_DEFINED -TA1 - rtems_port_create - RTEMS_INVALID_NAME -TA1 - rtems_port_create - RTEMS_INVALID_ADDRESS -TA1 - rtems_port_create - RTEMS_TOO_MANY -TA1 - rtems_port_delete - RTEMS_INVALID_ID -TA1 - rtems_port_ident - RTEMS_INVALID_NAME -TA1 - rtems_port_external_to_internal - RTEMS_INVALID_ID -TA1 - rtems_port_internal_to_external - RTEMS_INVALID_ID -<pause - screen 10> -TA1 - rtems_rate_monotonic_create - RTEMS_INVALID_NAME -TA1 - rtems_rate_monotonic_create - RTEMS_SUCCESSFUL -TA1 - rtems_rate_monotonic_create - RTEMS_TOO_MANY -TA1 - rtems_rate_monotonic_ident - RTEMS_INVALID_NAME -TA1 - rtems_rate_monotonic_period - unknown RTEMS_INVALID_ID -TA1 - rtems_rate_monotonic_period - local RTEMS_INVALID_ID -TA1 - rtems_rate_monotonic_period(RTEMS_PERIOD_STATUS) - RTEMS_NOT_DEFINED -TA1 - rtems_rate_monotonic_period - 100 ticks - RTEMS_SUCCESSFUL -TA1 - rtems_rate_monotonic_period(RTEMS_PERIOD_STATUS) - RTEMS_SUCCESSFUL -TA1 - rtems_rate_monotonic_period(RTEMS_PERIOD_STATUS) - RTEMS_TIMEOUT -TA1 - rtems_rate_monotonic_cancel - unknown RTEMS_INVALID_ID -TA1 - rtems_rate_monotonic_cancel - local RTEMS_INVALID_ID -TA1 - rtems_rate_monotonic_cancel - RTEMS_SUCCESSFUL -TA1 - rtems_rate_monotonic_period - 5 ticks - RTEMS_TIMEOUT -TA1 - yielding to TA4 -TA4 - rtems_rate_monotonic_cancel - RTEMS_NOT_OWNER_OF_RESOURCE -TA4 - rtems_rate_monotonic_period - RTEMS_NOT_OWNER_OF_RESOURCE -TA4 - rtems_task_delete - delete self - RTEMS_SUCCESSFUL -TA1 - rtems_rate_monotonic_delete - unknown RTEMS_INVALID_ID -TA1 - rtems_rate_monotonic_delete - local RTEMS_INVALID_ID -TA1 - rtems_rate_monotonic_delete - RTEMS_SUCCESSFUL -<pause - screen 11> -TA1 - rtems_partition_create - RTEMS_INVALID_NAME -TA1 - rtems_partition_create - length - RTEMS_INVALID_SIZE -TA1 - rtems_partition_create - buffer size - RTEMS_INVALID_SIZE -TA1 - rtems_partition_create - length < buffer size - RTEMS_INVALID_SIZE -TA1 - rtems_partition_create - RTEMS_MP_NOT_CONFIGURED -TA1 - rtems_partition_create - RTEMS_INVALID_ADDRESS -TA1 - rtems_partition_create - RTEMS_INVALID_SIZE -TA1 - rtems_partition_delete - unknown RTEMS_INVALID_ID -TA1 - rtems_partition_delete - local RTEMS_INVALID_ID -TA1 - rtems_partition_get_buffer - RTEMS_INVALID_ID -TA1 - rtems_partition_ident - RTEMS_INVALID_NAME -TA1 - rtems_partition_return_buffer - RTEMS_INVALID_ID -TA1 - rtems_partition_create - RTEMS_SUCCESSFUL -TA1 - rtems_partition_create - RTEMS_TOO_MANY -TA1 - rtems_partition_get_buffer - RTEMS_SUCCESSFUL -TA1 - rtems_partition_get_buffer - RTEMS_SUCCESSFUL -TA1 - rtems_partition_get_buffer - RTEMS_UNSATISFIED -TA1 - rtems_partition_delete - RTEMS_RESOURCE_IN_USE -TA1 - rtems_partition_return_buffer - RTEMS_INVALID_ADDRESS - out of range -TA1 - rtems_partition_return_buffer - RTEMS_INVALID_ADDRESS - not on boundary -<pause - screen 12> -TA1 - rtems_region_create - RTEMS_INVALID_NAME -TA1 - rtems_region_create - RTEMS_INVALID_ADDRESS -TA1 - rtems_region_create - RTEMS_INVALID_SIZE -TA1 - rtems_region_create - RTEMS_SUCCESSFUL -TA1 - rtems_region_create - RTEMS_TOO_MANY -TA1 - rtems_region_delete - unknown RTEMS_INVALID_ID -TA1 - rtems_region_delete - local RTEMS_INVALID_ID -TA1 - rtems_region_ident - RTEMS_INVALID_NAME -TA1 - rtems_region_get_segment - RTEMS_INVALID_ID -TA1 - rtems_region_get_segment - RTEMS_INVALID_SIZE -TA1 - rtems_region_get_segment - RTEMS_SUCCESSFUL -TA1 - rtems_region_get_segment - RTEMS_UNSATISFIED -TA1 - rtems_region_get_segment - timeout in 3 seconds -TA1 - rtems_region_get_segment - woke up with RTEMS_TIMEOUT -TA1 - rtems_region_delete - RTEMS_RESOURCE_IN_USE -TA1 - rtems_region_return_segment - RTEMS_INVALID_ID -TA1 - rtems_region_return_segment - RTEMS_INVALID_ADDRESS -TA1 - rtems_debug_disable - RTEMS_DEBUG_REGION -TA1 - rtems_region_return_segment - RTEMS_INVALID_ADDRESS - SKIPPED -TA1 - rtems_region_return_segment - RTEMS_INVALID_ADDRESS - SKIPPED -TA1 - rtems_debug_enable - RTEMS_DEBUG_REGION -TA1 - rtems_region_extend - RTEMS_INVALID_ID -TA1 - rtems_region_extend - within heap - RTEMS_INVALID_ADDRESS -TA1 - rtems_region_extend - non-contiguous lower - RTEMS_NOT_IMPLEMENTED -TA1 - rtems_region_extend - contiguous lower - RTEMS_NOT_IMPLEMENTED -TA1 - rtems_region_extend - non-contiguous higher - RTEMS_NOT_IMPLEMENTED -<pause - screen 13> -TA1 - rtems_io_close - RTEMS_INVALID_NUMBER -TA1 - rtems_io_control - RTEMS_INVALID_NUMBER -TA1 - rtems_io_initialize - RTEMS_INVALID_NUMBER -TA1 - rtems_io_open - RTEMS_INVALID_NUMBER -TA1 - rtems_io_read - RTEMS_INVALID_NUMBER -TA1 - rtems_io_write - RTEMS_INVALID_NUMBER -TA1 - rtems_clock_set - 23:59:59 12/31/2000 - RTEMS_SUCCESSFUL -TA1 - rtems_clock_get - 00:00:00 01/01/2001 - RTEMS_SUCCESSFUL -TA1 - rtems_clock_set - 23:59:59 12/31/1999 - RTEMS_SUCCESSFUL -TA1 - rtems_clock_get - 00:00:00 01/01/2000 - RTEMS_SUCCESSFUL -TA1 - rtems_clock_set - 23:59:59 12/31/2100 - RTEMS_SUCCESSFUL -TA1 - rtems_clock_get - 00:00:00 01/01/2101 - RTEMS_SUCCESSFUL -TA1 - rtems_clock_set - 23:59:59 12/31/2099 - RTEMS_SUCCESSFUL -TA1 - rtems_clock_get - 00:00:00 01/01/2100 - RTEMS_SUCCESSFUL -TA1 - rtems_clock_set - 23:59:59 12/31/1991 - RTEMS_SUCCESSFUL -TA1 - rtems_clock_get - 00:00:00 01/01/1992 - RTEMS_SUCCESSFUL -<pause - screen 14> -TA1 - rtems_timer_create - RTEMS_INVALID_NAME -TA1 - rtems_timer_create - 1 - RTEMS_SUCCESSFUL -TA1 - rtems_timer_create - 2 - RTEMS_TOO_MANY -TA1 - rtems_timer_delete - local RTEMS_INVALID_ID -TA1 - rtems_timer_delete - global RTEMS_INVALID_ID -TA1 - rtems_timer_ident - RTEMS_INVALID_NAME -TA1 - rtems_timer_cancel - RTEMS_INVALID_ID -TA1 - rtems_timer_reset - RTEMS_INVALID_ID -TA1 - rtems_timer_reset - RTEMS_NOT_DEFINED -TA1 - rtems_timer_fire_after - RTEMS_INVALID_ID -TA1 - rtems_timer_fire_when - RTEMS_INVALID_ID -TA1 - rtems_timer_fire_after - RTEMS_INVALID_NUMBER -TA1 - rtems_timer_fire_when - 08:30:45 02/05/1987 - RTEMS_INVALID_CLOCK -TA1 - rtems_clock_get - 00:00:01 01/01/1992 -TA1 - rtems_timer_fire_when - 08:30:45 02/05/1990 - before RTEMS_INVALID_CLOCK -TA1 - rtems_timer_server_fire_after - RTEMS_INCORRECT_STATE -TA1 - rtems_timer_server_fire_when - RTEMS_INCORRECT_STATE -TA1 - rtems_timer_initiate_server - RTEMS_INVALID_PRIORITY -TA1 - rtems_timer_initiate_server -TA1 - rtems_timer_server_fire_after - RTEMS_INVALID_ID -TA1 - rtems_timer_server_fire_when - RTEMS_INVALID_ID -TA1 - rtems_timer_server_fire_after - RTEMS_INVALID_NUMBER -TA1 - rtems_timer_server_fire_when - 08:30:45 02/05/1987 - RTEMS_INVALID_CLOCK -TA1 - rtems_clock_get - 00:00:01 01/01/1992 -TA1 - rtems_timer_server_fire_when - 08:30:45 02/05/1990 - before RTEMS_INVALID_CLOCK -*** END OF TEST 9 *** diff --git a/c/src/tests/sptests/sp09/system.h b/c/src/tests/sptests/sp09/system.h deleted file mode 100644 index d7fbfbeccb..0000000000 --- a/c/src/tests/sptests/sp09/system.h +++ /dev/null @@ -1,141 +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.com/license/LICENSE. - * - * $Id$ - */ - -#include <tmacros.h> - -/* functions */ - -rtems_task Init( - rtems_task_argument argument -); - -rtems_timer_service_routine Delayed_routine( - rtems_id ignored_id, - void *ignored_address -); - -rtems_task Task_1( - rtems_task_argument argument -); - -rtems_task Task_2( - rtems_task_argument argument -); - -rtems_task Task_3( - rtems_task_argument argument -); - -rtems_task Task_4( - rtems_task_argument argument -); - -rtems_isr Service_routine( - rtems_vector_number ignored -); - -rtems_timer_service_routine Io_during_interrupt( - rtems_id ignored -); - -void Screen1( void ); - -void Screen2( void ); - -void Screen3( void ); - -void Screen4( void ); - -void Screen5( void ); - -void Screen6( void ); - -void Screen7( void ); - -void Screen8( void ); - -void Screen9( void ); - -void Screen10( void ); - -void Screen11( void ); - -void Screen12( void ); - -void Screen13( void ); - -void Screen14( void ); - -/* configuration information */ - -#define CONFIGURE_APPLICATION_NEEDS_CONSOLE_DRIVER -#define CONFIGURE_APPLICATION_NEEDS_CLOCK_DRIVER - -#define CONFIGURE_MAXIMUM_TASKS 10 -#define CONFIGURE_MAXIMUM_TIMERS 1 -#define CONFIGURE_MAXIMUM_SEMAPHORES 2 -#define CONFIGURE_MAXIMUM_MESSAGE_QUEUES 1 -#define CONFIGURE_MAXIMUM_PARTITIONS 1 -#define CONFIGURE_MAXIMUM_REGIONS 1 -#define CONFIGURE_MAXIMUM_PERIODS 1 -#define CONFIGURE_MAXIMUM_USER_EXTENSIONS 0 -#define CONFIGURE_TICKS_PER_TIMESLICE 100 - -#define CONFIGURE_RTEMS_INIT_TASKS_TABLE - -#define CONFIGURE_EXTRA_TASK_STACKS (2 * RTEMS_MINIMUM_STACK_SIZE) - -#include <confdefs.h> - -/* global variables */ - -TEST_EXTERN rtems_id Task_id[ 11 ]; /* array of task ids */ -TEST_EXTERN rtems_name Task_name[ 11 ]; /* array of task names */ - -TEST_EXTERN rtems_name Timer_name[ 2 ]; /* array of timer names */ -TEST_EXTERN rtems_id Timer_id[ 2 ]; /* array of timer ids */ - -TEST_EXTERN rtems_name Semaphore_name[ 4 ]; /* array of semaphore names */ -TEST_EXTERN rtems_id Semaphore_id[ 4 ]; /* array of semaphore ids */ - -TEST_EXTERN rtems_name Queue_name[ 3 ]; /* array of queue names */ -TEST_EXTERN rtems_id Queue_id[ 3 ]; /* array of queue ids */ - -TEST_EXTERN rtems_name Partition_name[ 2 ]; /* array of partition names */ -TEST_EXTERN rtems_id Partition_id[ 2 ]; /* array of partition ids */ - -TEST_EXTERN rtems_name Region_name[ 2 ]; /* array of region names */ -TEST_EXTERN rtems_id Region_id[ 2 ]; /* array of region ids */ - -TEST_EXTERN rtems_name Port_name[ 2 ]; /* array of port names */ -TEST_EXTERN rtems_id Port_id[ 2 ]; /* array of port ids */ - -TEST_EXTERN rtems_name Period_name[ 2 ]; /* array of period names */ -TEST_EXTERN rtems_id Period_id[ 2 ]; /* array of period ids */ - -TEST_EXTERN rtems_id Junk_id; /* id used to return errors */ - -#define Internal_port_area (void *) 0x00001000 -#define External_port_area (void *) 0x00002000 - -TEST_EXTERN rtems_unsigned8 Partition_good_area[256] CPU_STRUCTURE_ALIGNMENT; -#define Partition_bad_area (void *) 0x00000006 - -TEST_EXTERN rtems_unsigned32 Region_good_area[4096] CPU_STRUCTURE_ALIGNMENT; -#define Region_bad_area (void *) 0x00000006 -#define REGION_START_OFFSET 1024 -#define REGION_LENGTH 512 - -/* end of include file */ diff --git a/c/src/tests/sptests/sp09/task1.c b/c/src/tests/sptests/sp09/task1.c deleted file mode 100644 index ff785d9438..0000000000 --- a/c/src/tests/sptests/sp09/task1.c +++ /dev/null @@ -1,69 +0,0 @@ -/* Task_1 - * - * This task generates all possible errors for the RTEMS executive. - * - * 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.com/license/LICENSE. - * - * $Id$ - */ - -#include "system.h" - -rtems_task Task_1( - rtems_task_argument argument -) -{ - Screen1(); - rtems_test_pause_and_screen_number( 2 ); - - Screen2(); - rtems_test_pause_and_screen_number( 3 ); - - Screen3(); - rtems_test_pause_and_screen_number( 4 ); - - Screen4(); - rtems_test_pause_and_screen_number( 5 ); - - Screen5(); - rtems_test_pause_and_screen_number( 6 ); - - Screen6(); - rtems_test_pause_and_screen_number( 7 ); - - Screen7(); - rtems_test_pause_and_screen_number( 8 ); - - Screen8(); - rtems_test_pause_and_screen_number( 9 ); - - Screen9(); - rtems_test_pause_and_screen_number( 10 ); - - Screen10(); - rtems_test_pause_and_screen_number( 11 ); - - Screen11(); - rtems_test_pause_and_screen_number( 12 ); - - Screen12(); - rtems_test_pause_and_screen_number( 13 ); - - Screen13(); - rtems_test_pause_and_screen_number( 14 ); - - Screen14(); - - puts( "*** END OF TEST 9 ***" ); - rtems_test_exit( 0 ); -} diff --git a/c/src/tests/sptests/sp09/task2.c b/c/src/tests/sptests/sp09/task2.c deleted file mode 100644 index 34dd3177e4..0000000000 --- a/c/src/tests/sptests/sp09/task2.c +++ /dev/null @@ -1,47 +0,0 @@ -/* Task_2 - * - * This routine serves as a test task. Its only purpose is to generate the - * error where a semaphore is deleted while a task is waiting for it. - * - * 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.com/license/LICENSE. - * - * $Id$ - */ - -#include "system.h" - -rtems_task Task_2( - rtems_task_argument argument -) -{ - rtems_status_code status; - - puts( "TA2 - rtems_semaphore_obtain - sem 1 - RTEMS_WAIT FOREVER" ); - status = rtems_semaphore_obtain( - Semaphore_id[ 1 ], - RTEMS_DEFAULT_OPTIONS, - RTEMS_NO_TIMEOUT - ); - fatal_directive_status( - status, - RTEMS_OBJECT_WAS_DELETED, - "rtems_semaphore_obtain waiting to be deleted" - ); - puts( - "TA2 - rtems_semaphore_obtain - woke up with RTEMS_OBJECT_WAS_DELETED" - ); - - puts( "TA2 - rtems_task_delete - delete self - RTEMS_SUCCESSFUL" ); - status = rtems_task_delete( RTEMS_SELF ); - directive_failed( status, "rtems_task_delete of TA2" ); -} diff --git a/c/src/tests/sptests/sp09/task3.c b/c/src/tests/sptests/sp09/task3.c deleted file mode 100644 index 1e437c9827..0000000000 --- a/c/src/tests/sptests/sp09/task3.c +++ /dev/null @@ -1,52 +0,0 @@ -/* Task_3 - * - * This routine serves as a test task. Its only purpose in life is to - * generate the error where a message queue is deleted while a task - * is waiting there for a message. - * - * 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.com/license/LICENSE. - * - * $Id$ - */ - -#include "system.h" - -rtems_task Task_3( - rtems_task_argument argument -) -{ - rtems_status_code status; - long buffer[ 4 ]; - rtems_unsigned32 size; - - puts( "TA3 - rtems_message_queue_receive - Q 1 - RTEMS_WAIT FOREVER" ); - status = rtems_message_queue_receive( - Queue_id[ 1 ], - (long (*)[4])buffer, - &size, - RTEMS_DEFAULT_OPTIONS, - RTEMS_NO_TIMEOUT - ); - fatal_directive_status( - status, - RTEMS_OBJECT_WAS_DELETED, - "rtems_message_queue_receive waiting to be deleted" - ); - puts( - "TA3 - rtems_message_queue_receive - woke up with RTEMS_OBJECT_WAS_DELETED" - ); - - puts( "TA3 - rtems_task_delete - delete self - RTEMS_SUCCESSFUL" ); - status = rtems_task_delete( RTEMS_SELF ); - directive_failed( status, "rtems_task_delete of TA3" ); -} diff --git a/c/src/tests/sptests/sp09/task4.c b/c/src/tests/sptests/sp09/task4.c deleted file mode 100644 index 736a6cc940..0000000000 --- a/c/src/tests/sptests/sp09/task4.c +++ /dev/null @@ -1,49 +0,0 @@ -/* Task_4 - * - * This routine serves as a test task. Its only purpose in life is to - * generate the error where a rate monotonic period is accessed by a - * task other than its creator. - * - * 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.com/license/LICENSE. - * - * $Id$ - */ - -#include "system.h" - -rtems_task Task_4( - rtems_task_argument argument -) -{ - rtems_status_code status; - - status = rtems_rate_monotonic_cancel( Period_id[ 1 ] ); - fatal_directive_status( - status, - RTEMS_NOT_OWNER_OF_RESOURCE, - "rtems_rate_monotonic_cancel not the owner" - ); - puts( "TA4 - rtems_rate_monotonic_cancel - RTEMS_NOT_OWNER_OF_RESOURCE" ); - - status = rtems_rate_monotonic_period( Period_id[ 1 ], 5 ); - fatal_directive_status( - status, - RTEMS_NOT_OWNER_OF_RESOURCE, - "rtems_rate_monotonic_period not the owner" - ); - puts( "TA4 - rtems_rate_monotonic_period - RTEMS_NOT_OWNER_OF_RESOURCE" ); - - puts( "TA4 - rtems_task_delete - delete self - RTEMS_SUCCESSFUL" ); - status = rtems_task_delete( RTEMS_SELF ); - directive_failed( status, "rtems_task_delete of TA4" ); -} |