summaryrefslogtreecommitdiffstats
path: root/testsuites
diff options
context:
space:
mode:
authorJoel Sherrill <joel.sherrill@OARcorp.com>2009-05-10 14:39:46 +0000
committerJoel Sherrill <joel.sherrill@OARcorp.com>2009-05-10 14:39:46 +0000
commitb84f1fdc0dddc6f5293b863f511c4f799a653b96 (patch)
tree5048e98e3972f9d06950088da4a1a9f568e33226 /testsuites
parentFix most warnings. (diff)
downloadrtems-b84f1fdc0dddc6f5293b863f511c4f799a653b96.tar.bz2
2009-05-10 Joel Sherrill <joel.sherrill@oarcorp.com>
* sp04/system.h, sp04/task1.c, sp04/tswitch.c, sp07/init.c, sp12/init.c, sp13/putbuff.c, sp13/system.h, sp13/task1.c, sp15/init.c, sp16/system.h, sp19/fptask.c, sp25/system.h, sp26/task1.c, sp27/init.c, sp28/init.c, sp29/init.c, sp31/task1.c, sp33/init.c, sp34/changepri.c, sp35/priinv.c, sp37/init.c, sp38/init.c, sp39/init.c, sp41/init.c, sp42/init.c, sp43/init.c, sp44/init.c, sp45/init.c, sp46/init.c, sp47/init.c, sp48/init.c, spfatal03/testcase.h, spfatal05/testcase.h, spfatal06/testcase.h, spfatal_support/system.h, spobjgetnext/init.c, spsize/getint.c, spsize/size.c: Fix warnings.
Diffstat (limited to 'testsuites')
-rw-r--r--testsuites/sptests/ChangeLog13
-rw-r--r--testsuites/sptests/sp04/system.h8
-rw-r--r--testsuites/sptests/sp04/task1.c6
-rw-r--r--testsuites/sptests/sp04/tswitch.c4
-rw-r--r--testsuites/sptests/sp07/init.c6
-rw-r--r--testsuites/sptests/sp12/init.c4
-rw-r--r--testsuites/sptests/sp13/putbuff.c9
-rw-r--r--testsuites/sptests/sp13/system.h4
-rw-r--r--testsuites/sptests/sp13/task1.c33
-rw-r--r--testsuites/sptests/sp15/init.c4
-rw-r--r--testsuites/sptests/sp16/system.h4
-rw-r--r--testsuites/sptests/sp19/fptask.c4
-rw-r--r--testsuites/sptests/sp25/system.h4
-rw-r--r--testsuites/sptests/sp26/task1.c4
-rw-r--r--testsuites/sptests/sp27/init.c11
-rw-r--r--testsuites/sptests/sp28/init.c20
-rw-r--r--testsuites/sptests/sp29/init.c12
-rw-r--r--testsuites/sptests/sp31/task1.c7
-rw-r--r--testsuites/sptests/sp33/init.c16
-rw-r--r--testsuites/sptests/sp34/changepri.c20
-rw-r--r--testsuites/sptests/sp35/priinv.c23
-rw-r--r--testsuites/sptests/sp37/init.c24
-rw-r--r--testsuites/sptests/sp38/init.c7
-rw-r--r--testsuites/sptests/sp39/init.c11
-rw-r--r--testsuites/sptests/sp41/init.c13
-rw-r--r--testsuites/sptests/sp42/init.c12
-rw-r--r--testsuites/sptests/sp43/init.c13
-rw-r--r--testsuites/sptests/sp44/init.c3
-rw-r--r--testsuites/sptests/sp45/init.c10
-rw-r--r--testsuites/sptests/sp46/init.c9
-rw-r--r--testsuites/sptests/sp47/init.c3
-rw-r--r--testsuites/sptests/sp48/init.c9
-rw-r--r--testsuites/sptests/spfatal03/testcase.h14
-rw-r--r--testsuites/sptests/spfatal05/testcase.h11
-rw-r--r--testsuites/sptests/spfatal06/testcase.h4
-rw-r--r--testsuites/sptests/spfatal_support/system.h15
-rw-r--r--testsuites/sptests/spobjgetnext/init.c7
-rw-r--r--testsuites/sptests/spsize/getint.c4
-rw-r--r--testsuites/sptests/spsize/size.c12
39 files changed, 307 insertions, 90 deletions
diff --git a/testsuites/sptests/ChangeLog b/testsuites/sptests/ChangeLog
index c010607daf..b06e2cc3a5 100644
--- a/testsuites/sptests/ChangeLog
+++ b/testsuites/sptests/ChangeLog
@@ -1,3 +1,16 @@
+2009-05-10 Joel Sherrill <joel.sherrill@oarcorp.com>
+
+ * sp04/system.h, sp04/task1.c, sp04/tswitch.c, sp07/init.c,
+ sp12/init.c, sp13/putbuff.c, sp13/system.h, sp13/task1.c,
+ sp15/init.c, sp16/system.h, sp19/fptask.c, sp25/system.h,
+ sp26/task1.c, sp27/init.c, sp28/init.c, sp29/init.c, sp31/task1.c,
+ sp33/init.c, sp34/changepri.c, sp35/priinv.c, sp37/init.c,
+ sp38/init.c, sp39/init.c, sp41/init.c, sp42/init.c, sp43/init.c,
+ sp44/init.c, sp45/init.c, sp46/init.c, sp47/init.c, sp48/init.c,
+ spfatal03/testcase.h, spfatal05/testcase.h, spfatal06/testcase.h,
+ spfatal_support/system.h, spobjgetnext/init.c, spsize/getint.c,
+ spsize/size.c: Fix warnings.
+
2009-05-07 Joel Sherrill <joel.sherrill@oarcorp.com>
* Makefile.am, configure.ac: Add initial test of _Objects_Get_next.
diff --git a/testsuites/sptests/sp04/system.h b/testsuites/sptests/sp04/system.h
index a932108d6d..98206bcd27 100644
--- a/testsuites/sptests/sp04/system.h
+++ b/testsuites/sptests/sp04/system.h
@@ -3,7 +3,7 @@
* This include file contains information that is included in every
* function in the test set.
*
- * COPYRIGHT (c) 1989-1999.
+ * COPYRIGHT (c) 1989-2009.
* On-Line Applications Research Corporation (OAR).
*
* The license and distribution terms for this file may be
@@ -69,13 +69,13 @@ TEST_EXTERN volatile uint32_t Run_count[ 4 ];
*/
struct taskSwitchLog {
- int taskIndex;
+ unsigned int taskIndex;
rtems_time_of_day when;
};
extern struct taskSwitchLog taskSwitchLog[];
-extern int taskSwitchLogIndex;
-volatile extern int testsFinished;
+extern unsigned int taskSwitchLogIndex;
+extern volatile int testsFinished;
/* end of include file */
diff --git a/testsuites/sptests/sp04/task1.c b/testsuites/sptests/sp04/task1.c
index 5eb249e648..e712568e6a 100644
--- a/testsuites/sptests/sp04/task1.c
+++ b/testsuites/sptests/sp04/task1.c
@@ -8,7 +8,7 @@
*
* Output parameters: NONE
*
- * COPYRIGHT (c) 1989-1999.
+ * COPYRIGHT (c) 1989-2009.
* On-Line Applications Research Corporation (OAR).
*
* The license and distribution terms for this file may be
@@ -23,8 +23,8 @@
static void
showTaskSwitches (void)
{
- int i;
- int switches = taskSwitchLogIndex;
+ unsigned int i;
+ unsigned int switches = taskSwitchLogIndex;
for (i = 0 ; i < switches ; i++) {
put_name( Task_name[taskSwitchLog[i].taskIndex], FALSE );
diff --git a/testsuites/sptests/sp04/tswitch.c b/testsuites/sptests/sp04/tswitch.c
index 79cda908fe..bb0cfc7513 100644
--- a/testsuites/sptests/sp04/tswitch.c
+++ b/testsuites/sptests/sp04/tswitch.c
@@ -10,7 +10,7 @@
*
* Output parameters: NONE
*
- * COPYRIGHT (c) 1989-1999.
+ * COPYRIGHT (c) 1989-2009.
* On-Line Applications Research Corporation (OAR).
*
* The license and distribution terms for this file may be
@@ -23,7 +23,7 @@
#include "system.h"
struct taskSwitchLog taskSwitchLog[1000];
-int taskSwitchLogIndex;
+unsigned int taskSwitchLogIndex;
volatile int testsFinished;
rtems_extension Task_switch(
diff --git a/testsuites/sptests/sp07/init.c b/testsuites/sptests/sp07/init.c
index 0d34a58699..58018ab6a2 100644
--- a/testsuites/sptests/sp07/init.c
+++ b/testsuites/sptests/sp07/init.c
@@ -11,7 +11,7 @@
*
* Output parameters: NONE
*
- * COPYRIGHT (c) 1989-2008.
+ * COPYRIGHT (c) 1989-2009.
* On-Line Applications Research Corporation (OAR).
*
* The license and distribution terms for this file may be
@@ -132,7 +132,7 @@ rtems_task Init(
);
directive_failed( status, "rtems_task_create of TA2" );
-#define TA3_PRIORITY (RTEMS_MAXIMUM_PRIORITY - 4)
+#define TA3_PRIORITY (RTEMS_MAXIMUM_PRIORITY - 4u)
status = rtems_task_create(
Task_name[ 3 ],
TA3_PRIORITY,
@@ -143,7 +143,7 @@ rtems_task Init(
);
directive_failed( status, "rtems_task_create of TA3" );
-#define TA4_PRIORITY (RTEMS_MAXIMUM_PRIORITY - 1)
+#define TA4_PRIORITY (RTEMS_MAXIMUM_PRIORITY - 1u)
status = rtems_task_create(
Task_name[ 4 ],
TA4_PRIORITY,
diff --git a/testsuites/sptests/sp12/init.c b/testsuites/sptests/sp12/init.c
index f68e9d477e..e828821ae6 100644
--- a/testsuites/sptests/sp12/init.c
+++ b/testsuites/sptests/sp12/init.c
@@ -11,7 +11,7 @@
*
* Output parameters: NONE
*
- * COPYRIGHT (c) 1989-2008.
+ * COPYRIGHT (c) 1989-2009.
* On-Line Applications Research Corporation (OAR).
*
* The license and distribution terms for this file may be
@@ -79,7 +79,7 @@ rtems_task Init(
Priority_test_driver( 0 );
puts( "INIT - Backward priority queue test" );
- Priority_test_driver( (RTEMS_MAXIMUM_PRIORITY / 2) + 1 );
+ Priority_test_driver( (RTEMS_MAXIMUM_PRIORITY / 2u) + 1u );
rtems_test_pause();
diff --git a/testsuites/sptests/sp13/putbuff.c b/testsuites/sptests/sp13/putbuff.c
index 004ce76dc0..d580db6532 100644
--- a/testsuites/sptests/sp13/putbuff.c
+++ b/testsuites/sptests/sp13/putbuff.c
@@ -8,7 +8,7 @@
*
* Output parameters: NONE
*
- * COPYRIGHT (c) 1989-1999.
+ * COPYRIGHT (c) 1989-2009.
* On-Line Applications Research Corporation (OAR).
*
* The license and distribution terms for this file may be
@@ -21,15 +21,16 @@
#include "system.h"
void Put_buffer(
- long *buffer
+ void *buffer
)
{
int i, j;
char c;
+ long *b = buffer;
- for ( i = 0; i < MESSAGE_SIZE / sizeof(long); i++ ) {
+ for ( i = 0; i < (int) (MESSAGE_SIZE / sizeof(long)); i++ ) {
for ( j = sizeof(long) - 1; j >= 0; j-- ) {
- if ( (c = (buffer[i] >> (8 * j)) & 0xFF) == 0 )
+ if ( (c = (char)(b[i] >> (8 * j)) & 0xFF) == 0 )
return;
printf( "%c", c );
}
diff --git a/testsuites/sptests/sp13/system.h b/testsuites/sptests/sp13/system.h
index 53b76b124b..efc38ecfc2 100644
--- a/testsuites/sptests/sp13/system.h
+++ b/testsuites/sptests/sp13/system.h
@@ -3,7 +3,7 @@
* This include file contains information that is included in every
* function in the test set.
*
- * COPYRIGHT (c) 1989-20007.
+ * COPYRIGHT (c) 1989-2009.
* On-Line Applications Research Corporation (OAR).
*
* The license and distribution terms for this file may be
@@ -27,7 +27,7 @@ void Fill_buffer(
);
void Put_buffer(
- long *buffer
+ void *buffer
);
rtems_task Task_1(
diff --git a/testsuites/sptests/sp13/task1.c b/testsuites/sptests/sp13/task1.c
index 57f1cf4725..471f861d4d 100644
--- a/testsuites/sptests/sp13/task1.c
+++ b/testsuites/sptests/sp13/task1.c
@@ -7,7 +7,7 @@
*
* Output parameters: NONE
*
- * COPYRIGHT (c) 1989-2007.
+ * COPYRIGHT (c) 1989-2009.
* On-Line Applications Research Corporation (OAR).
*
* The license and distribution terms for this file may be
@@ -20,26 +20,33 @@
#include "system.h"
#include <string.h> /* for memcmp */
+void dope_buffer(
+ unsigned char *buff,
+ int buff_size,
+ unsigned char v
+);
+
unsigned char big_send_buffer[2048];
unsigned char big_receive_buffer[2048];
long buffer[ MESSAGE_SIZE / sizeof(long) ];
-void dope_buffer(unsigned char *buff,
- int buff_size,
- uint32_t v)
+void dope_buffer(
+ unsigned char *buff,
+ int buff_size,
+ unsigned char v
+)
{
- int i;
- unsigned char ch;
+ int i;
+ unsigned char ch;
- ch = (' ' + (v % (0x7f - ' ')));
+ ch = (' ' + (v % (0x7f - ' ')));
- for (i=0; i<buff_size; i++)
- {
- *buff++ = ch++;
- if (ch >= 0x7f)
- ch = ' ';
- }
+ for (i=0; i<buff_size; i++) {
+ *buff++ = ch++;
+ if (ch >= 0x7f)
+ ch = ' ';
+ }
}
rtems_task Task_1(
diff --git a/testsuites/sptests/sp15/init.c b/testsuites/sptests/sp15/init.c
index 86d3d73fa9..e5ef35ac83 100644
--- a/testsuites/sptests/sp15/init.c
+++ b/testsuites/sptests/sp15/init.c
@@ -11,7 +11,7 @@
*
* Output parameters: NONE
*
- * COPYRIGHT (c) 1989-1999.
+ * COPYRIGHT (c) 1989-2009.
* On-Line Applications Research Corporation (OAR).
*
* The license and distribution terms for this file may be
@@ -39,7 +39,7 @@ rtems_task Init(
status = rtems_task_create(
Task_name[ 1 ],
- 4,
+ 4u,
RTEMS_MINIMUM_STACK_SIZE,
RTEMS_DEFAULT_MODES,
RTEMS_DEFAULT_ATTRIBUTES,
diff --git a/testsuites/sptests/sp16/system.h b/testsuites/sptests/sp16/system.h
index a0600a6fa3..f7e4c99190 100644
--- a/testsuites/sptests/sp16/system.h
+++ b/testsuites/sptests/sp16/system.h
@@ -3,7 +3,7 @@
* This include file contains information that is included in every
* function in the test set.
*
- * COPYRIGHT (c) 1989-2008.
+ * COPYRIGHT (c) 1989-2009.
* On-Line Applications Research Corporation (OAR).
*
* The license and distribution terms for this file may be
@@ -68,7 +68,7 @@ TEST_EXTERN uint8_t Area_2[4096] CPU_STRUCTURE_ALIGNMENT;
TEST_EXTERN uint8_t Area_3[4096] CPU_STRUCTURE_ALIGNMENT;
TEST_EXTERN uint8_t Area_4[8192] CPU_STRUCTURE_ALIGNMENT;
-#define BASE_PRIORITY ((RTEMS_MAXIMUM_PRIORITY / 2) + 1)
+#define BASE_PRIORITY ((RTEMS_MAXIMUM_PRIORITY / 2u) + 1u)
#define Put_address_from_area_1( _to_be_printed ) \
printf( "0x%08lx", \
diff --git a/testsuites/sptests/sp19/fptask.c b/testsuites/sptests/sp19/fptask.c
index 7a0cc7773b..5a1ba16438 100644
--- a/testsuites/sptests/sp19/fptask.c
+++ b/testsuites/sptests/sp19/fptask.c
@@ -9,7 +9,7 @@
*
* Output parameters: NONE
*
- * COPYRIGHT (c) 1989-1999.
+ * COPYRIGHT (c) 1989-2009.
* On-Line Applications Research Corporation (OAR).
*
* The license and distribution terms for this file may be
@@ -52,7 +52,7 @@ rtems_task FP_task(
printf( " - float base = (NA)\n" );
#endif
- previous_seconds = -1;
+ previous_seconds = (uint32_t)-1;
while( FOREVER ) {
diff --git a/testsuites/sptests/sp25/system.h b/testsuites/sptests/sp25/system.h
index 0da04e56e0..5017faf180 100644
--- a/testsuites/sptests/sp25/system.h
+++ b/testsuites/sptests/sp25/system.h
@@ -3,7 +3,7 @@
* This include file contains information that is included in every
* function in the test set.
*
- * COPYRIGHT (c) 1989-2008.
+ * COPYRIGHT (c) 1989-2009.
* On-Line Applications Research Corporation (OAR).
*
* The license and distribution terms for this file may be
@@ -47,7 +47,7 @@ TEST_EXTERN rtems_name Region_name[ 2 ]; /* array of region names */
/* test will fail... segment sizes need to be reworked for <=32K buffer */
TEST_EXTERN uint8_t Area_1[20*1024] CPU_STRUCTURE_ALIGNMENT;
-#define BASE_PRIORITY ((RTEMS_MAXIMUM_PRIORITY / 2) + 1)
+#define BASE_PRIORITY ((RTEMS_MAXIMUM_PRIORITY / 2u) + 1u)
#define Put_address_from_area_1( _to_be_printed ) \
printf( "0x%08lx", \
diff --git a/testsuites/sptests/sp26/task1.c b/testsuites/sptests/sp26/task1.c
index 86f04fe840..4de36dea31 100644
--- a/testsuites/sptests/sp26/task1.c
+++ b/testsuites/sptests/sp26/task1.c
@@ -1,5 +1,5 @@
/*
- * COPYRIGHT (c) 1989-2008.
+ * COPYRIGHT (c) 1989-2009.
* On-Line Applications Research Corporation (OAR).
*
* The license and distribution terms for this file may be
@@ -85,7 +85,7 @@ createTask (char c, rtems_id *tid)
rtems_status_code sc;
sc = rtems_task_create (rtems_build_name('S','u','b',c),
- RTEMS_MAXIMUM_PRIORITY - 1,
+ RTEMS_MAXIMUM_PRIORITY - 1u,
RTEMS_MINIMUM_STACK_SIZE * 4,
RTEMS_PREEMPT|RTEMS_NO_TIMESLICE|RTEMS_NO_ASR|RTEMS_INTERRUPT_LEVEL(0),
RTEMS_NO_FLOATING_POINT|RTEMS_LOCAL,
diff --git a/testsuites/sptests/sp27/init.c b/testsuites/sptests/sp27/init.c
index d617fbf850..6150631b8d 100644
--- a/testsuites/sptests/sp27/init.c
+++ b/testsuites/sptests/sp27/init.c
@@ -1,12 +1,21 @@
/*
* Test for rtems_semaphore_flush
*
+ * COPYRIGHT (c) 1989-2009.
+ * On-Line Applications Research Corporation (OAR).
+ *
+ * The license and distribution terms for this file may be
+ * found in the file LICENSE in this distribution or at
+ * http://www.rtems.com/license/LICENSE.
+ *
* $Id$
*/
#include <bsp.h>
rtems_task Init (rtems_task_argument argument);
+void starttask(int arg);
+rtems_task subtask(rtems_task_argument arg);
#define CONFIGURE_RTEMS_INIT_TASKS_TABLE
@@ -64,7 +73,7 @@ starttask (int arg)
printf ("Can't create task: %s\n", rtems_status_text (sc));
rtems_task_suspend (RTEMS_SELF);
}
- sc = rtems_task_start (tid, subtask, arg);
+ sc = rtems_task_start (tid, subtask, (rtems_task_argument) arg);
if (sc != RTEMS_SUCCESSFUL) {
printf ("Can't start task: %s\n", rtems_status_text (sc));
rtems_task_suspend (RTEMS_SELF);
diff --git a/testsuites/sptests/sp28/init.c b/testsuites/sptests/sp28/init.c
index ce7c5e738e..18411f0ac9 100644
--- a/testsuites/sptests/sp28/init.c
+++ b/testsuites/sptests/sp28/init.c
@@ -1,4 +1,7 @@
/*
+ * COPYRIGHT (c) 1989-2009.
+ * On-Line Applications Research Corporation (OAR).
+ *
* The license and distribution terms for this file may be
* found in the file LICENSE in this distribution or at
* http://www.rtems.com/license/LICENSE.
@@ -28,6 +31,17 @@ rtems_task Init(rtems_task_argument argument);
#include <rtems/error.h>
#include <stdio.h>
+rtems_task subtask(rtems_task_argument arg);
+rtems_task Task_variable_deleter(rtems_task_argument ignored);
+void starttask(int arg);
+void test_errors(void);
+void test_dtor(void *pointer);
+void test_multiple_taskvars(void);
+void test_out_of_memory(void);
+rtems_task Other_Task(rtems_task_argument ignored);
+void test_delete_from_other_task(void);
+void test_delete_as_side_effect(void);
+
volatile void *taskvar;
volatile int nRunning;
volatile int nDeleted;
@@ -96,7 +110,7 @@ starttask (int arg)
rtems_status_code sc;
sc = rtems_task_create(rtems_build_name ('S', 'R', 'V', arg + 'A'),
- RTEMS_MAXIMUM_PRIORITY - 1,
+ RTEMS_MAXIMUM_PRIORITY - 1u,
RTEMS_MINIMUM_STACK_SIZE,
RTEMS_PREEMPT|RTEMS_NO_TIMESLICE|RTEMS_NO_ASR|RTEMS_INTERRUPT_LEVEL(0),
RTEMS_NO_FLOATING_POINT|RTEMS_LOCAL,
@@ -280,7 +294,7 @@ void test_delete_from_other_task(void)
directive_failed( sc, "add for other task case" );
sc = rtems_task_create(rtems_build_name ('O', 'T', 'H', 'R'),
- RTEMS_MAXIMUM_PRIORITY - 1,
+ RTEMS_MAXIMUM_PRIORITY - 1u,
RTEMS_MINIMUM_STACK_SIZE,
RTEMS_PREEMPT|RTEMS_NO_TIMESLICE|RTEMS_NO_ASR|RTEMS_INTERRUPT_LEVEL(0),
RTEMS_NO_FLOATING_POINT|RTEMS_LOCAL,
@@ -327,7 +341,7 @@ void test_delete_as_side_effect(void)
test_dtor_ran = 0;
sc = rtems_task_create(rtems_build_name ('O', 'T', 'H', 'R'),
- RTEMS_MAXIMUM_PRIORITY - 1,
+ RTEMS_MAXIMUM_PRIORITY - 1u,
RTEMS_MINIMUM_STACK_SIZE,
RTEMS_PREEMPT|RTEMS_NO_TIMESLICE|RTEMS_NO_ASR|RTEMS_INTERRUPT_LEVEL(0),
RTEMS_NO_FLOATING_POINT|RTEMS_LOCAL,
diff --git a/testsuites/sptests/sp29/init.c b/testsuites/sptests/sp29/init.c
index ffe40bd6e0..9db3d0e2d9 100644
--- a/testsuites/sptests/sp29/init.c
+++ b/testsuites/sptests/sp29/init.c
@@ -1,6 +1,10 @@
/*
* Test for rtems_semaphore_flush
*
+ * 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$
*/
@@ -26,6 +30,8 @@ rtems_task Init (rtems_task_argument argument);
#include <stdlib.h>
rtems_interval ticksPerSecond;
+rtems_task subtask(rtems_task_argument arg);
+void startTask(rtems_id arg);
rtems_task
subtask (rtems_task_argument arg)
@@ -49,7 +55,7 @@ startTask (rtems_id arg)
rtems_status_code sc;
sc = rtems_task_create (rtems_build_name ('S', 'R', 'V', 'A'),
- RTEMS_MAXIMUM_PRIORITY - 1,
+ RTEMS_MAXIMUM_PRIORITY - 1u,
RTEMS_MINIMUM_STACK_SIZE * 2,
RTEMS_PREEMPT|RTEMS_NO_TIMESLICE|RTEMS_NO_ASR|RTEMS_INTERRUPT_LEVEL(0),
RTEMS_NO_FLOATING_POINT|RTEMS_LOCAL,
@@ -172,11 +178,11 @@ rtems_task Init (rtems_task_argument ignored)
sc = rtems_semaphore_obtain (semnorec, RTEMS_WAIT, RTEMS_NO_TIMEOUT);
rtems_clock_get (RTEMS_CLOCK_GET_TICKS_SINCE_BOOT, &now);
- diff = now - then;
+ diff = (int) (now - then);
then = now;
if (sc != RTEMS_SUCCESSFUL)
printf ("%d: Failed to obtain non-recursive-lock semaphore: %s\n", __LINE__, rtems_status_text (sc));
- else if (diff < (2 * ticksPerSecond))
+ else if (diff < (int) (2 * ticksPerSecond))
printf ("%d: Obtained obtain non-recursive-lock semaphore too quickly -- %d ticks not %d ticks\n", __LINE__, diff, (2 * ticksPerSecond) );
}
diff --git a/testsuites/sptests/sp31/task1.c b/testsuites/sptests/sp31/task1.c
index f7e7d9a3e0..c59bf01558 100644
--- a/testsuites/sptests/sp31/task1.c
+++ b/testsuites/sptests/sp31/task1.c
@@ -8,7 +8,7 @@
*
* Output parameters: NONE
*
- * COPYRIGHT (c) 1989-2002.
+ * COPYRIGHT (c) 1989-2009.
* On-Line Applications Research Corporation (OAR).
*
* The license and distribution terms for this file may be
@@ -20,6 +20,11 @@
#include "system.h"
+rtems_timer_service_routine Should_not_fire_TSR(
+ rtems_id ignored_id,
+ void *ignored_address
+);
+
volatile int TSR_fired;
rtems_timer_service_routine Should_not_fire_TSR(
diff --git a/testsuites/sptests/sp33/init.c b/testsuites/sptests/sp33/init.c
index a7547aca99..1d812ad78c 100644
--- a/testsuites/sptests/sp33/init.c
+++ b/testsuites/sptests/sp33/init.c
@@ -1,8 +1,12 @@
-/* spmonotonic -- sanity check the rate monotonic manager
+/*
+ * spmonotonic -- sanity check the rate monotonic manager
*
- * 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 .
+ * COPYRIGHT (c) 1989-2009.
+ * On-Line Applications Research Corporation (OAR).
+ *
+ * The license and distribution terms for this file may be
+ * found in the file LICENSE in this distribution or at
+ * http://www.rtems.com/license/LICENSE.
*
* $Id$
*/
@@ -22,6 +26,10 @@ rtems_task Init (rtems_task_argument ignored);
#define CONFIGURE_INIT
+rtems_task Waiter(
+ rtems_task_argument number
+);
+
rtems_id Barrier;
int SuccessfulCase;
diff --git a/testsuites/sptests/sp34/changepri.c b/testsuites/sptests/sp34/changepri.c
index 71a16fdcff..16e1574919 100644
--- a/testsuites/sptests/sp34/changepri.c
+++ b/testsuites/sptests/sp34/changepri.c
@@ -2,6 +2,10 @@
* Test program to demonstrate reordering of threads on thread queues
* when their priority changes.
*
+ * 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$
*/
@@ -24,11 +28,13 @@
#include "tmacros.h"
rtems_task BlockingTasks(rtems_task_argument arg);
+rtems_task Init(rtems_task_argument ignored);
+const char *CallerName(void);
/*
* CallerName -- print the calling tasks name or id as configured
*/
-const char *CallerName()
+const char *CallerName(void)
{
static char buffer[32];
#if defined(TEST_PRINT_TASK_ID)
@@ -110,7 +116,7 @@ rtems_task Init(rtems_task_argument ignored)
for (i = 0; i < NUMBER_OF_BLOCKING_TASKS; i++) {
status = rtems_task_create(
rtems_build_name('B','L','K','0'+i), /* Name */
- 2+i, /* Priority */
+ (rtems_task_priority) 2+i, /* Priority */
RTEMS_MINIMUM_STACK_SIZE*2, /* Stack size (8KB) */
RTEMS_DEFAULT_MODES | RTEMS_NO_ASR, /* Mode */
RTEMS_DEFAULT_ATTRIBUTES | RTEMS_FLOATING_POINT, /* Attributes */
@@ -118,7 +124,11 @@ rtems_task Init(rtems_task_argument ignored)
directive_failed( status, "rtems_task_create (BLKn)" );
printf( "Blockers[%d] Id = 0x%08x\n", i, Blockers[i] );
- status = rtems_task_start(Blockers[i], BlockingTasks, i);
+ status = rtems_task_start(
+ Blockers[i],
+ BlockingTasks,
+ (rtems_task_argument)i
+ );
directive_failed( status, "rtems_task_start (BLKn)" );
}
@@ -128,7 +138,9 @@ rtems_task Init(rtems_task_argument ignored)
puts( "rtems_task_set_priority -- invert priorities of tasks" );
for (i = 0; i < NUMBER_OF_BLOCKING_TASKS; i++) {
rtems_task_priority opri;
- rtems_task_priority npri= 2 + NUMBER_OF_BLOCKING_TASKS - i - 1;
+ rtems_task_priority npri;
+
+ npri = (rtems_task_priority) (2 + NUMBER_OF_BLOCKING_TASKS - i - 1);
status = rtems_task_set_priority(Blockers[i], npri, &opri);
directive_failed( status, "rtems_task_set_priority" );
diff --git a/testsuites/sptests/sp35/priinv.c b/testsuites/sptests/sp35/priinv.c
index 6d1e4506cb..a78b3ceb6d 100644
--- a/testsuites/sptests/sp35/priinv.c
+++ b/testsuites/sptests/sp35/priinv.c
@@ -7,6 +7,10 @@
* e-mail: ulf.ivraeus@space.se
* ----------------------------- --- -- - - -
*
+ * 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$
*/
@@ -56,7 +60,10 @@
volatile uint32_t Iterations = 0;
#endif
+const char *CallerName(void);
+
/* Task entry point prototypes */
+rtems_task Init(rtems_task_argument ignored);
rtems_task Medium_Exec(rtems_task_argument TaskArg);
rtems_task Low_Exec(rtems_task_argument TaskArg);
rtems_task High_Exec(rtems_task_argument TaskArg);
@@ -69,7 +76,7 @@ rtems_isr LocalHwIsr(/*in*/ rtems_vector_number Vector);
void AccessLocalHw(void);
void AccessRemoteHw(void);
-const char *CallerName()
+const char *CallerName(void)
{
static char buffer[32];
#if defined(TEST_PRINT_TASK_ID)
@@ -410,7 +417,7 @@ rtems_task Init(rtems_task_argument ignored)
/* -- Medium-prio Test Tasks --- */
for (i = 0; i < NofMediumTask_C; i++) {
-#define MEDIUM_PRIORITY ((RTEMS_MAXIMUM_PRIORITY / 2) + 1)
+#define MEDIUM_PRIORITY ((RTEMS_MAXIMUM_PRIORITY / 2u) + 1u)
status = rtems_task_create(
rtems_build_name('M','E','D','0'+i), /* Name */
MEDIUM_PRIORITY, /* Priority */
@@ -421,12 +428,16 @@ rtems_task Init(rtems_task_argument ignored)
directive_failed( status, "rtems_task_create (MEDn)" );
printf( "TaMedium[%d] Id = 0x%08x\n", i, TaMedium[i] );
- status = rtems_task_start(TaMedium[i], Medium_Exec, i);
+ status = rtems_task_start(
+ TaMedium[i],
+ Medium_Exec,
+ (rtems_task_argument) i
+ );
directive_failed( status, "rtems_task_start (MEDn)" );
}
/* -- High-prio Test Task --- */
-#define HIGH_PRIORITY ((RTEMS_MAXIMUM_PRIORITY / 2))
+#define HIGH_PRIORITY ((RTEMS_MAXIMUM_PRIORITY / 2u))
status = rtems_task_create(
rtems_build_name('H','I','G','H'), /* Name */
HIGH_PRIORITY, /* Priority */
@@ -441,7 +452,7 @@ rtems_task Init(rtems_task_argument ignored)
directive_failed( status, "rtems_task_start (HIGH)" );
/* -- Low-prio Test Task --- */
-#define LOW_PRIORITY (RTEMS_MAXIMUM_PRIORITY - 1)
+#define LOW_PRIORITY (RTEMS_MAXIMUM_PRIORITY - 1u)
status = rtems_task_create(
rtems_build_name('L','O','W',' '), /* Name */
LOW_PRIORITY, /* Priority */
@@ -456,7 +467,7 @@ rtems_task Init(rtems_task_argument ignored)
directive_failed( status, "rtems_task_start (LOW)" );
/* -- HW Simulator Task --- */
-#define HWTASK_PRIORITY (RTEMS_MAXIMUM_PRIORITY - 2)
+#define HWTASK_PRIORITY (RTEMS_MAXIMUM_PRIORITY - 2u)
status = rtems_task_create(
rtems_build_name('H','W','S','M'), /* Name */
HWTASK_PRIORITY, /* Priority */
diff --git a/testsuites/sptests/sp37/init.c b/testsuites/sptests/sp37/init.c
index e016e364b3..a3ddd66c2b 100644
--- a/testsuites/sptests/sp37/init.c
+++ b/testsuites/sptests/sp37/init.c
@@ -2,7 +2,7 @@
* Interrupt Disable/Enable Tests
* Clock Tick from task level
*
- * COPYRIGHT (c) 1989-2007.
+ * COPYRIGHT (c) 1989-2009.
* On-Line Applications Research Corporation (OAR).
*
* The license and distribution terms for this file may be
@@ -16,6 +16,28 @@
#define CONFIGURE_INIT
#include "system.h"
+/* prototypes */
+void test_interrupt_inline(void);
+void check_isr_in_progress_inline(void);
+rtems_task blocked_task(rtems_task_argument argument);
+rtems_timer_service_routine test_unblock_task(
+ rtems_id timer,
+ void *arg
+);
+rtems_timer_service_routine test_unblock_task(
+ rtems_id timer,
+ void *arg
+);
+void check_isr_worked(
+ char *s,
+ int result
+);
+rtems_timer_service_routine test_isr_in_progress(
+ rtems_id timer,
+ void *arg
+);
+
+/* test bodies */
void test_interrupt_inline(void)
{
rtems_interrupt_level level;
diff --git a/testsuites/sptests/sp38/init.c b/testsuites/sptests/sp38/init.c
index d31b9fd119..8943cd0042 100644
--- a/testsuites/sptests/sp38/init.c
+++ b/testsuites/sptests/sp38/init.c
@@ -1,7 +1,7 @@
/*
* Classic API Signal to Task from ISR
*
- * COPYRIGHT (c) 1989-2007.
+ * COPYRIGHT (c) 1989-2009.
* On-Line Applications Research Corporation (OAR).
*
* The license and distribution terms for this file may be
@@ -18,6 +18,11 @@ volatile bool signal_sent;
volatile bool signal_processed;
rtems_id main_task;
+void signal_handler(rtems_signal_set signals);
+rtems_timer_service_routine test_signal_from_isr(
+ rtems_id timer,
+ void *arg
+);
void signal_handler(
rtems_signal_set signals
diff --git a/testsuites/sptests/sp39/init.c b/testsuites/sptests/sp39/init.c
index 570d6c3f42..fb89137583 100644
--- a/testsuites/sptests/sp39/init.c
+++ b/testsuites/sptests/sp39/init.c
@@ -1,7 +1,7 @@
/*
* Classic API Signal to Task from ISR
*
- * COPYRIGHT (c) 1989-2008.
+ * COPYRIGHT (c) 1989-2009.
* On-Line Applications Research Corporation (OAR).
*
* The license and distribution terms for this file may be
@@ -14,6 +14,15 @@
#define CONFIGURE_INIT
#include "system.h"
+rtems_timer_service_routine test_event_from_isr(
+ rtems_id timer,
+ void *arg
+);
+rtems_timer_service_routine test_event_with_timeout_from_isr(
+ rtems_id timer,
+ void *arg
+);
+
volatile bool case_hit;
rtems_id main_task;
diff --git a/testsuites/sptests/sp41/init.c b/testsuites/sptests/sp41/init.c
index db6c2c42a3..d60a4b2a7d 100644
--- a/testsuites/sptests/sp41/init.c
+++ b/testsuites/sptests/sp41/init.c
@@ -1,7 +1,7 @@
/*
* Classic API Signal to Task from ISR
*
- * COPYRIGHT (c) 1989-2008.
+ * COPYRIGHT (c) 1989-2009.
* On-Line Applications Research Corporation (OAR).
*
* The license and distribution terms for this file may be
@@ -20,6 +20,17 @@ volatile bool case_hit;
rtems_id main_task;
rtems_id Semaphore;
+/* prototypes */
+Thread_blocking_operation_States getState(void);
+rtems_timer_service_routine test_release_from_isr(
+ rtems_id timer,
+ void *arg
+);
+rtems_timer_service_routine test_release_with_timeout_from_isr(
+ rtems_id timer,
+ void *arg
+);
+
Thread_blocking_operation_States getState(void)
{
Objects_Locations location;
diff --git a/testsuites/sptests/sp42/init.c b/testsuites/sptests/sp42/init.c
index da02b1cbb6..54e24080f9 100644
--- a/testsuites/sptests/sp42/init.c
+++ b/testsuites/sptests/sp42/init.c
@@ -1,7 +1,7 @@
/*
* Exercise thread queue enqueue and dequeue priority
*
- * COPYRIGHT (c) 1989-2008.
+ * COPYRIGHT (c) 1989-2009.
* On-Line Applications Research Corporation (OAR).
*
* The license and distribution terms for this file may be
@@ -20,6 +20,13 @@
#define MAX_TASKS 20
+rtems_task Init(rtems_task_argument argument);
+rtems_task Locker_task(rtems_task_argument unused);
+void do_test(
+ rtems_attribute attr,
+ bool extract /* TRUE if extract, not release */
+);
+
/*
* Carefully chosen to exercise threadq enqueue/dequeue priority logic.
* Somewhat randomly sorted to ensure than if discipline is FIFO, run-time
@@ -108,7 +115,8 @@ void do_test(
);
directive_failed( status, "rtems_task_create" );
- status = rtems_task_start( Task_id[ i ], Locker_task, i );
+ status = rtems_task_start(
+ Task_id[ i ], Locker_task, (rtems_task_argument)i );
directive_failed( status, "rtems_task_start" );
status = rtems_task_wake_after( 10 );
diff --git a/testsuites/sptests/sp43/init.c b/testsuites/sptests/sp43/init.c
index d3e796cbfe..68901e892d 100644
--- a/testsuites/sptests/sp43/init.c
+++ b/testsuites/sptests/sp43/init.c
@@ -1,7 +1,7 @@
/*
* Exercise Object Manager Services
*
- * COPYRIGHT (c) 1989-2008.
+ * COPYRIGHT (c) 1989-2009.
* On-Line Applications Research Corporation (OAR).
*
* The license and distribution terms for this file may be
@@ -23,6 +23,17 @@
#undef rtems_object_id_get_index
#undef rtems_object_id_get_node
+void print_class_info(
+ uint32_t api,
+ uint32_t class,
+ rtems_object_api_class_information *info
+);
+void change_name(
+ rtems_id id,
+ const char *newName,
+ bool printable
+);
+
rtems_id main_task;
rtems_name main_name;
diff --git a/testsuites/sptests/sp44/init.c b/testsuites/sptests/sp44/init.c
index 4e39de1286..0af5205c3a 100644
--- a/testsuites/sptests/sp44/init.c
+++ b/testsuites/sptests/sp44/init.c
@@ -32,6 +32,9 @@
#include <stdio.h>
#include <stdlib.h>
+rtems_task Init(rtems_task_argument ignored);
+rtems_task TaskAB_entry(rtems_task_argument me);
+
/*** Task priorities ***/
#define TASK_A_PRIORITY 10
#define TASK_B_PRIORITY 10
diff --git a/testsuites/sptests/sp45/init.c b/testsuites/sptests/sp45/init.c
index 2619740222..ed10d7c87d 100644
--- a/testsuites/sptests/sp45/init.c
+++ b/testsuites/sptests/sp45/init.c
@@ -1,5 +1,5 @@
/*
- * COPYRIGHT (c) 1989-2008.
+ * COPYRIGHT (c) 1989-2009.
* On-Line Applications Research Corporation (OAR).
*
* The license and distribution terms for this file may be
@@ -11,6 +11,14 @@
#include <tmacros.h>
+rtems_task Init(
+ rtems_task_argument argument
+);
+rtems_timer_service_routine Malloc_From_TSR(
+ rtems_id ignored_id,
+ void *ignored_address
+);
+
rtems_id Timer_id[ 3 ]; /* array of timer ids */
rtems_name Timer_name[ 3 ]; /* array of timer names */
diff --git a/testsuites/sptests/sp46/init.c b/testsuites/sptests/sp46/init.c
index b0d91439cd..f3163677af 100644
--- a/testsuites/sptests/sp46/init.c
+++ b/testsuites/sptests/sp46/init.c
@@ -1,5 +1,5 @@
/*
- * COPYRIGHT (c) 1989-2008.
+ * COPYRIGHT (c) 1989-2009.
* On-Line Applications Research Corporation (OAR).
*
* The license and distribution terms for this file may be
@@ -12,6 +12,13 @@
#include <tmacros.h>
#include <rtems/cpuuse.h>
+rtems_task Periodic_Task(
+ rtems_task_argument argument
+);
+rtems_task Init(
+ rtems_task_argument argument
+);
+
volatile int partial_loop = 0;
rtems_task Periodic_Task(
diff --git a/testsuites/sptests/sp47/init.c b/testsuites/sptests/sp47/init.c
index d0115fab0f..5416f51016 100644
--- a/testsuites/sptests/sp47/init.c
+++ b/testsuites/sptests/sp47/init.c
@@ -6,6 +6,9 @@
#include <tmacros.h>
+rtems_task test_asr(rtems_task_argument unused);
+rtems_task Init(rtems_task_argument ignored);
+
rtems_task test_asr(rtems_task_argument unused)
{
rtems_mode mode;
diff --git a/testsuites/sptests/sp48/init.c b/testsuites/sptests/sp48/init.c
index 33c8315c1c..7d5c40db05 100644
--- a/testsuites/sptests/sp48/init.c
+++ b/testsuites/sptests/sp48/init.c
@@ -1,12 +1,21 @@
/*
* Verify creation of semaphores with unlimited attribute works.
*
+ * COPYRIGHT (c) 1989-2009.
+ * On-Line Applications Research Corporation (OAR).
+ *
+ * The license and distribution terms for this file may be
+ * found in the file LICENSE in this distribution or at
+ * http://www.rtems.com/license/LICENSE.
+ *
* $Id$
*/
#include <tmacros.h>
#include <rtems/libcsupport.h>
+rtems_task Init(rtems_task_argument ignored);
+
#define MAX 5000
rtems_id Semaphores[MAX];
diff --git a/testsuites/sptests/spfatal03/testcase.h b/testsuites/sptests/spfatal03/testcase.h
index 0c72212863..0eb8589e4e 100644
--- a/testsuites/sptests/spfatal03/testcase.h
+++ b/testsuites/sptests/spfatal03/testcase.h
@@ -1,5 +1,12 @@
/*
- * Classic API Init task create failure
+ * Classic API Init task create failure
+ *
+ * COPYRIGHT (c) 1989-2009.
+ * On-Line Applications Research Corporation (OAR).
+ *
+ * The license and distribution terms for this file may be
+ * found in the file LICENSE in this distribution or at
+ * http://www.rtems.com/license/LICENSE.
*
* $Id$
*/
@@ -34,12 +41,10 @@ rtems_initialization_tasks_table Initialization_tasks[] = {
rtems_id Mutex_id[1];
rtems_name Mutex_name[1];
-void force_error()
+void force_error(void)
{
- ISR_Level level;
rtems_status_code status;
-
Mutex_name[0] = rtems_build_name( 'S','0',' ',' ');
status = rtems_semaphore_create(
Mutex_name[0],
@@ -60,7 +65,6 @@ void force_error()
/* !!! SHOULD NOT RETURN FROM THE ABOVE CALL */
_Thread_Enable_dispatch();
- _ISR_Enable( level );
directive_failed( status, "rtems_semaphore_obtain" );
/* we will not run this far */
diff --git a/testsuites/sptests/spfatal05/testcase.h b/testsuites/sptests/spfatal05/testcase.h
index b7a33027aa..3fca0921d6 100644
--- a/testsuites/sptests/spfatal05/testcase.h
+++ b/testsuites/sptests/spfatal05/testcase.h
@@ -1,5 +1,12 @@
/*
- * Classic API Init task create failure
+ * Classic API Init task create failure
+ *
+ * COPYRIGHT (c) 1989-2009.
+ * On-Line Applications Research Corporation (OAR).
+ *
+ * The license and distribution terms for this file may be
+ * found in the file LICENSE in this distribution or at
+ * http://www.rtems.com/license/LICENSE.
*
* $Id$
*/
@@ -31,6 +38,8 @@ rtems_initialization_tasks_table Initialization_tasks[] = {
#define FATAL_ERROR_EXPECTED_IS_INTERNAL TRUE
#define FATAL_ERROR_EXPECTED_ERROR INTERNAL_ERROR_THREAD_EXITTED
+rtems_task EmptyTask( rtems_task_argument unused );
+
rtems_task EmptyTask(
rtems_task_argument unused
)
diff --git a/testsuites/sptests/spfatal06/testcase.h b/testsuites/sptests/spfatal06/testcase.h
index 81d1c1e8fe..d17f7792ce 100644
--- a/testsuites/sptests/spfatal06/testcase.h
+++ b/testsuites/sptests/spfatal06/testcase.h
@@ -1,5 +1,5 @@
/*
- * Classic API Init task create failure
+ * Classic API Init task create failure
*
* COPYRIGHT (c) 1989-2008.
* On-Line Applications Research Corporation (OAR).
@@ -36,6 +36,8 @@ rtems_initialization_tasks_table Initialization_tasks[] = {
#define FATAL_ERROR_EXPECTED_IS_INTERNAL TRUE
#define FATAL_ERROR_EXPECTED_ERROR INTERNAL_ERROR_BAD_STACK_HOOK
+void *New_stack_allocate_hook(uint32_t unused);
+
void *New_stack_allocate_hook(uint32_t unused)
{
}
diff --git a/testsuites/sptests/spfatal_support/system.h b/testsuites/sptests/spfatal_support/system.h
index e55d50d69d..61f279e1f9 100644
--- a/testsuites/sptests/spfatal_support/system.h
+++ b/testsuites/sptests/spfatal_support/system.h
@@ -3,7 +3,7 @@
* This include file contains information that is included in every
* function in the test set.
*
- * COPYRIGHT (c) 1989-1999.
+ * COPYRIGHT (c) 1989-2009.
* On-Line Applications Research Corporation (OAR).
*
* The license and distribution terms for this file may be
@@ -32,7 +32,18 @@ rtems_extension Fatal_extension(
uint32_t error
);
-/* need prototypes */
+void Put_Error(
+ uint32_t source,
+ uint32_t error
+);
+
+void Put_Source(
+ uint32_t source
+);
+
+void force_error(void);
+
+/* need some prototypes for test cases */
#include "testcase.h"
diff --git a/testsuites/sptests/spobjgetnext/init.c b/testsuites/sptests/spobjgetnext/init.c
index 5058a69fff..eaabffcf65 100644
--- a/testsuites/sptests/spobjgetnext/init.c
+++ b/testsuites/sptests/spobjgetnext/init.c
@@ -15,7 +15,14 @@
#define __RTEMS_VIOLATE_KERNEL_VISIBILITY__ 1
#include "system.h"
+/* prototypes */
+int scan_objects(
+ Objects_Information *information,
+ Objects_Id start
+);
+
#define MAX_SCAN 10
+
int scan_objects(
Objects_Information *information,
Objects_Id start
diff --git a/testsuites/sptests/spsize/getint.c b/testsuites/sptests/spsize/getint.c
index f6f5f61f16..0bf9215670 100644
--- a/testsuites/sptests/spsize/getint.c
+++ b/testsuites/sptests/spsize/getint.c
@@ -8,7 +8,7 @@
* Output parameters:
* returns - number read
*
- * COPYRIGHT (c) 1989-1999.
+ * COPYRIGHT (c) 1989-2009.
* On-Line Applications Research Corporation (OAR).
*
* The license and distribution terms for this file may be
@@ -22,6 +22,8 @@
#include <stdio.h>
#include <stdlib.h>
+int getint( void );
+
int getint( void )
{
char buff[16];
diff --git a/testsuites/sptests/spsize/size.c b/testsuites/sptests/spsize/size.c
index fc02005664..ce0026b514 100644
--- a/testsuites/sptests/spsize/size.c
+++ b/testsuites/sptests/spsize/size.c
@@ -1,9 +1,8 @@
-/* main
- *
+/*
* This program is run to determine the data space and work space
* requirements of the current version of RTEMS.
*
- * COPYRIGHT (c) 1989-2008.
+ * COPYRIGHT (c) 1989-2009.
* On-Line Applications Research Corporation (OAR).
*
* The license and distribution terms for this file may be
@@ -52,6 +51,10 @@
/* external function prototypes */
int getint( void );
+void size_rtems(int mode);
+void help_size(void);
+void print_formula(void);
+
/* These are always defined by the executive.
*
@@ -134,9 +137,6 @@ extern CORE_semaphore_Control _MPCI_Semaphore;
uint32_t sys_req;
-void help_size();
-void print_formula();
-
void size_rtems(
int mode
)