diff options
author | Joel Sherrill <joel.sherrill@OARcorp.com> | 2010-07-27 13:54:56 +0000 |
---|---|---|
committer | Joel Sherrill <joel.sherrill@OARcorp.com> | 2010-07-27 13:54:56 +0000 |
commit | a7d32373148109accbd532a4425bc063617d6203 (patch) | |
tree | 2e793045248cd0834b55c235a92a7c0144a24f33 /testsuites | |
parent | Apply missing commit. (diff) | |
download | rtems-a7d32373148109accbd532a4425bc063617d6203.tar.bz2 |
*** empty log message ***
Diffstat (limited to 'testsuites')
-rw-r--r-- | testsuites/libtests/devfs04/devfs04.doc | 3 | ||||
-rw-r--r-- | testsuites/libtests/devfs04/init.c | 5 | ||||
-rw-r--r-- | testsuites/libtests/devfs04/test_driver.c | 4 |
3 files changed, 9 insertions, 3 deletions
diff --git a/testsuites/libtests/devfs04/devfs04.doc b/testsuites/libtests/devfs04/devfs04.doc index 965d89a030..02eff67f2a 100644 --- a/testsuites/libtests/devfs04/devfs04.doc +++ b/testsuites/libtests/devfs04/devfs04.doc @@ -17,6 +17,7 @@ directives: + devFS_read + devFS_write ++ null_initialize concepts: @@ -24,3 +25,5 @@ concepts: paths in the read / write routines for devFS. These are invoked using the system calls read() and write(). ++ The write call is forwarded to null_write, thus exercising +null_write too. diff --git a/testsuites/libtests/devfs04/init.c b/testsuites/libtests/devfs04/init.c index 01ac7feee6..e89708a7c6 100644 --- a/testsuites/libtests/devfs04/init.c +++ b/testsuites/libtests/devfs04/init.c @@ -18,6 +18,7 @@ #include <sys/stat.h> #include <fcntl.h> #include "test_driver.h" +#include <rtems/devnull.h> rtems_task Init( rtems_task_argument argument @@ -60,8 +61,10 @@ rtems_task Init( rtems_test_assert( status == -1 ); rtems_test_assert( errno == ENOSYS ); - puts( "*** END OF TEST DEVFS04 ***" ); + status = mknod( "/dev/null", 0777 | S_IFCHR, 0LL ); + rtems_test_assert( status == 0 ); + puts( "*** END OF TEST DEVFS04 ***" ); rtems_test_exit(0); } diff --git a/testsuites/libtests/devfs04/test_driver.c b/testsuites/libtests/devfs04/test_driver.c index 7006c8529a..958ce33acf 100644 --- a/testsuites/libtests/devfs04/test_driver.c +++ b/testsuites/libtests/devfs04/test_driver.c @@ -17,7 +17,7 @@ #include <rtems.h> #include "test_driver.h" #include <rtems/libio.h> - +#include <rtems/devnull.h> /* * The test driver routines are mostly derived from the null driver routines. */ @@ -158,7 +158,7 @@ rtems_device_driver testDriver_write( if ( rw_args ) { if( rw_args->count == 5 ) - rw_args->bytes_moved = rw_args->count; + return null_write( 0, 0, pargp ); else { rw_args->bytes_moved = 0; return RTEMS_NOT_IMPLEMENTED; |