forked from Imagelibrary/rtems
testsuites: Fix warnings
This commit is contained in:
@@ -196,7 +196,10 @@ static void test_ide_part_table(void)
|
||||
rtems_status_code sc = RTEMS_SUCCESSFUL;
|
||||
|
||||
test_logical_disks(&ide_part_table_rdax [0], false);
|
||||
#pragma GCC diagnostic push
|
||||
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
|
||||
sc = rtems_ide_part_table_initialize(rda);
|
||||
#pragma GCC diagnostic pop
|
||||
ASSERT_SC(sc);
|
||||
test_logical_disks(&ide_part_table_rdax [0], true);
|
||||
}
|
||||
|
||||
@@ -29,7 +29,7 @@
|
||||
#include "fstest.h"
|
||||
#include "pmacros.h"
|
||||
|
||||
volatile void *prevent_compiler_optimizations;
|
||||
void *volatile prevent_compiler_optimizations;
|
||||
|
||||
/* Break out of a chroot() environment in C */
|
||||
static void break_out_of_chroot(void)
|
||||
|
||||
@@ -2,11 +2,14 @@
|
||||
*************** Dump of Entire IMFS ***************
|
||||
/
|
||||
....dev/
|
||||
........console_a (device 0, 0)
|
||||
........console (device 0, 0)
|
||||
........console_b (device 0, 1)
|
||||
*************** End of Dump ***************
|
||||
stat of /dev/console
|
||||
....st_dev (0xfffe:0x0)
|
||||
....st_ino 3 may vary by small amount
|
||||
....st_rdev (0x0:0x0)
|
||||
....st_ino 4 may vary by small amount
|
||||
....mode = 00020755
|
||||
....nlink = 1
|
||||
....uid = 0
|
||||
@@ -14,7 +17,7 @@ stat of /dev/console
|
||||
....atime = Fri Jan 1 00:00:00 1988
|
||||
....mtime = Fri Jan 1 00:00:00 1988
|
||||
....ctime = Fri Jan 1 00:00:00 1988
|
||||
....st_blksize 80
|
||||
....st_blksize 0
|
||||
....st_blocks 0
|
||||
|
||||
mkdir /dev/tty
|
||||
@@ -31,7 +34,6 @@ rmdir /usr
|
||||
rmdir /dev
|
||||
rmdir /fred
|
||||
rmdir /tmp/bha
|
||||
unlink /dev/tty
|
||||
mknod /dev/test_console
|
||||
mknod /dev/tty/S3
|
||||
mknod /etc/passwd
|
||||
@@ -48,7 +50,6 @@ unlink /tmp
|
||||
create and close /tmp/tom
|
||||
Attempt to recreate /tmp/tom
|
||||
create /tmp/john
|
||||
tcdrain /tmp/john
|
||||
Attempt to create a file, open in read-only mode and truncate it
|
||||
Exercise the reentrant version _link_r -- Expect ENOENT
|
||||
Unlink /tmp/bha using the reentrant version -- OK
|
||||
@@ -85,7 +86,8 @@ End of _rename_r tests
|
||||
|
||||
stat( /tmp/joel ) returned
|
||||
....st_dev (0xfffe:0x0)
|
||||
....st_ino 15 may vary by small amount
|
||||
....st_rdev (0x0:0x0)
|
||||
....st_ino 17 may vary by small amount
|
||||
....mode = 00100700
|
||||
....nlink = 1
|
||||
....uid = 0
|
||||
@@ -118,7 +120,8 @@ Skipping maximum file size test since max_size is 4329344 bytes
|
||||
That is likely to be bigger than the available RAM on many targets.
|
||||
stat( /tmp/joel ) returned
|
||||
....st_dev (0xfffe:0x0)
|
||||
....st_ino 16 may vary by small amount
|
||||
....st_rdev (0x0:0x0)
|
||||
....st_ino 18 may vary by small amount
|
||||
....mode = 00100700
|
||||
....nlink = 1
|
||||
....uid = 0
|
||||
@@ -130,16 +133,17 @@ stat( /tmp/joel ) returned
|
||||
....st_blocks 0
|
||||
stat of /tmp/j
|
||||
stat(/tmp/j) returned -1 (errno=2)
|
||||
....st_dev (0xfffe:0x0)
|
||||
....st_ino 3 may vary by small amount
|
||||
....mode = 00020755
|
||||
....nlink = 1
|
||||
....st_dev (0x0:0x0)
|
||||
....st_rdev (0x0:0x0)
|
||||
....st_ino 0 may vary by small amount
|
||||
....mode = 00000000
|
||||
....nlink = 0
|
||||
....uid = 0
|
||||
....gid = 0
|
||||
....atime = Fri Jan 1 00:00:00 1988
|
||||
....mtime = Fri Jan 1 00:00:00 1988
|
||||
....ctime = Fri Jan 1 00:00:00 1988
|
||||
....st_blksize 80
|
||||
....atime = Thu Jan 1 00:00:00 1970
|
||||
....mtime = Thu Jan 1 00:00:00 1970
|
||||
....ctime = Thu Jan 1 00:00:00 1970
|
||||
....st_blksize 0
|
||||
....st_blocks 0
|
||||
fopen of /tmp/j
|
||||
fprintf to /tmp/j
|
||||
@@ -149,7 +153,8 @@ fprintf to /tmp/j
|
||||
(4) 26 characters written to the file
|
||||
(5) 26 characters written to the file
|
||||
....st_dev (0xfffe:0x0)
|
||||
....st_ino 17 may vary by small amount
|
||||
....st_rdev (0x0:0x0)
|
||||
....st_ino 19 may vary by small amount
|
||||
....mode = 00100644
|
||||
....nlink = 1
|
||||
....uid = 0
|
||||
@@ -165,7 +170,8 @@ This is call 3 to fprintf
|
||||
This is call 4 to fprintf
|
||||
This is call 5 to fprintf
|
||||
....st_dev (0xfffe:0x0)
|
||||
....st_ino 17 may vary by small amount
|
||||
....st_rdev (0x0:0x0)
|
||||
....st_ino 19 may vary by small amount
|
||||
....mode = 00100644
|
||||
....nlink = 1
|
||||
....uid = 0
|
||||
@@ -178,7 +184,9 @@ This is call 5 to fprintf
|
||||
*************** Dump of Entire IMFS ***************
|
||||
/
|
||||
....dev/
|
||||
........console_a (device 0, 0)
|
||||
........console (device 0, 0)
|
||||
........console_b (device 0, 1)
|
||||
........tty/
|
||||
............S3 (device 255, 128)
|
||||
........test_console (device 0, 0)
|
||||
@@ -195,7 +203,8 @@ This is call 5 to fprintf
|
||||
*************** End of Dump ***************
|
||||
truncate /tmp/j to length of 40
|
||||
....st_dev (0xfffe:0x0)
|
||||
....st_ino 17 may vary by small amount
|
||||
....st_rdev (0x0:0x0)
|
||||
....st_ino 19 may vary by small amount
|
||||
....mode = 00100644
|
||||
....nlink = 1
|
||||
....uid = 0
|
||||
@@ -208,7 +217,9 @@ truncate /tmp/j to length of 40
|
||||
*************** Dump of Entire IMFS ***************
|
||||
/
|
||||
....dev/
|
||||
........console_a (device 0, 0)
|
||||
........console (device 0, 0)
|
||||
........console_b (device 0, 1)
|
||||
........tty/
|
||||
............S3 (device 255, 128)
|
||||
........test_console (device 0, 0)
|
||||
@@ -229,7 +240,9 @@ truncate /tmp to length of 0 should fail with EISDIR
|
||||
*************** Dump of Entire IMFS ***************
|
||||
/
|
||||
....dev/
|
||||
........console_a (device 0, 0)
|
||||
........console (device 0, 0)
|
||||
........console_b (device 0, 1)
|
||||
........tty/
|
||||
............S3 (device 255, 128)
|
||||
........test_console (device 0, 0)
|
||||
|
||||
@@ -35,6 +35,7 @@
|
||||
#include <unistd.h>
|
||||
#include <errno.h>
|
||||
#include <string.h>
|
||||
#include <inttypes.h>
|
||||
#include <ctype.h>
|
||||
#include <reent.h>
|
||||
#include <rtems/imfs.h>
|
||||
@@ -80,15 +81,16 @@ void test_extend(
|
||||
*/
|
||||
void dump_statbuf( struct stat *buf )
|
||||
{
|
||||
int major1;
|
||||
int minor1;
|
||||
int major2;
|
||||
int minor2;
|
||||
rtems_device_major_number major1;
|
||||
rtems_device_minor_number minor1;
|
||||
rtems_device_major_number major2;
|
||||
rtems_device_minor_number minor2;
|
||||
|
||||
rtems_filesystem_split_dev_t( buf->st_dev, major1, minor1 );
|
||||
rtems_filesystem_split_dev_t( buf->st_rdev, major2, minor2 );
|
||||
|
||||
printf( "....st_dev (0x%x:0x%x)\n", major1, minor1 );
|
||||
printf( "....st_dev (0x%" PRIx32 ":0x%" PRIx32 ")\n", major1, minor1 );
|
||||
printf( "....st_rdev (0x%" PRIx32 ":0x%" PRIx32 ")\n", major2, minor2 );
|
||||
printf( "....st_ino %" PRIxino_t " may vary by small amount\n", buf->st_ino );
|
||||
printf( "....mode = %08" PRIomode_t "\n", buf->st_mode );
|
||||
printf( "....nlink = %d\n", buf->st_nlink );
|
||||
|
||||
@@ -12,6 +12,7 @@
|
||||
#endif
|
||||
|
||||
#include <timesys.h>
|
||||
#include <pthread.h>
|
||||
#include <rtems/timerdrv.h>
|
||||
#include "test_support.h"
|
||||
|
||||
|
||||
@@ -27,6 +27,7 @@
|
||||
#include <stdio.h>
|
||||
#include <time.h>
|
||||
#include <errno.h>
|
||||
#include <sched.h>
|
||||
#include <timesys.h>
|
||||
#include <tmacros.h>
|
||||
#include <rtems/timerdrv.h>
|
||||
@@ -88,16 +89,14 @@ void *Middle(
|
||||
|
||||
#elif defined(USE_TIMEDWAIT_WAIT_VALUE_IN_PAST)
|
||||
{
|
||||
long end_time;
|
||||
|
||||
/* override sleepTime with something obviously in the past */
|
||||
sleepTime.tv_sec = 0;
|
||||
sleepTime.tv_nsec = 5;
|
||||
|
||||
/* this does all the work of timedwait but immediately returns */
|
||||
rc = pthread_cond_timedwait( &CondID, &MutexID, &sleepTime );
|
||||
end_time = benchmark_timer_read();
|
||||
rtems_test_assert(rc == ETIMEDOUT);
|
||||
benchmark_timer_read();
|
||||
}
|
||||
#endif
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
/* forward declarations to avoid warnings */
|
||||
void *POSIX_Init(void *argument);
|
||||
void benchmark_pthread_create(void);
|
||||
void thread(void *argument);
|
||||
void *thread(void *argument);
|
||||
|
||||
void benchmark_pthread_create(void)
|
||||
{
|
||||
@@ -46,11 +46,12 @@ void benchmark_pthread_create(void)
|
||||
|
||||
}
|
||||
|
||||
void thread(
|
||||
void *thread(
|
||||
void *argument
|
||||
)
|
||||
{
|
||||
//Empty thread used in pthread_create().
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void *POSIX_Init(
|
||||
|
||||
@@ -23,7 +23,6 @@ rtems_task Init(
|
||||
char ch;
|
||||
rtems_id id;
|
||||
rtems_status_code status;
|
||||
bool allDone;
|
||||
|
||||
/* Put start of test message */
|
||||
puts( "\n\n*** spatomic02 TEST ***\n" );
|
||||
|
||||
@@ -23,7 +23,6 @@ rtems_task Init(
|
||||
char ch;
|
||||
rtems_id id;
|
||||
rtems_status_code status;
|
||||
bool allDone;
|
||||
|
||||
/* Put start of test message */
|
||||
puts( "\n\n*** spatomic03 TEST ***\n" );
|
||||
|
||||
@@ -23,7 +23,6 @@ rtems_task Init(
|
||||
char ch;
|
||||
rtems_id id;
|
||||
rtems_status_code status;
|
||||
bool allDone;
|
||||
|
||||
/* Put start of test message */
|
||||
puts( "\n\n*** spatomic04 TEST ***\n" );
|
||||
|
||||
@@ -23,7 +23,6 @@ rtems_task Init(
|
||||
char ch;
|
||||
rtems_id id;
|
||||
rtems_status_code status;
|
||||
bool allDone;
|
||||
|
||||
/* Put start of test message */
|
||||
puts( "\n\n*** spatomic05 TEST ***\n" );
|
||||
|
||||
@@ -23,7 +23,6 @@ rtems_task Init(
|
||||
char ch;
|
||||
rtems_id id;
|
||||
rtems_status_code status;
|
||||
bool allDone;
|
||||
|
||||
/* Put start of test message */
|
||||
puts( "\n\n*** spatomic06 TEST ***\n" );
|
||||
|
||||
@@ -23,7 +23,6 @@ rtems_task Init(
|
||||
char ch;
|
||||
rtems_id id;
|
||||
rtems_status_code status;
|
||||
bool allDone;
|
||||
|
||||
/* Put start of test message */
|
||||
puts( "\n\n*** spatomic07 TEST ***\n" );
|
||||
|
||||
@@ -28,8 +28,6 @@
|
||||
void boot_card( const char *cmdline )
|
||||
{
|
||||
_Internal_error_Occurred( FATAL_SOURCE, FATAL_IS_INTERNAL, FATAL_ERROR );
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
static void fatal_extension(
|
||||
|
||||
@@ -23,8 +23,8 @@
|
||||
static void test_internal_error_description(void)
|
||||
{
|
||||
rtems_fatal_code error = 0;
|
||||
const char *desc_last = NULL;
|
||||
const char *desc;
|
||||
const char *desc = NULL;
|
||||
const char *desc_last;
|
||||
|
||||
do {
|
||||
desc_last = desc;
|
||||
@@ -39,8 +39,8 @@ static void test_internal_error_description(void)
|
||||
static void test_fatal_source_description(void)
|
||||
{
|
||||
rtems_fatal_source source = 0;
|
||||
const char *desc_last = NULL;
|
||||
const char *desc;
|
||||
const char *desc = NULL;
|
||||
const char *desc_last;
|
||||
|
||||
do {
|
||||
desc_last = desc;
|
||||
|
||||
Reference in New Issue
Block a user