diff options
author | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2010-06-08 08:30:04 +0000 |
---|---|---|
committer | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2010-06-08 08:30:04 +0000 |
commit | 78f4d6d72ef51e9bdd33e2ed258fb6af5701153e (patch) | |
tree | 78eb811bad5ea57d3ba3036a9acd020153f758dd /cpukit/libfs/src/imfs/deviceio.c | |
parent | 2010-06-07 Bharath Suri <bharath.s.jois@gmail.com> (diff) | |
download | rtems-78f4d6d72ef51e9bdd33e2ed258fb6af5701153e.tar.bz2 |
2010-06-08 Sebastian Huber <sebastian.huber@embedded-brains.de>
* libfs/src/devfs/devclose.c, libfs/src/devfs/devopen.c,
libfs/src/imfs/deviceerrno.c, libfs/src/imfs/deviceio.c,
libfs/src/rfs/rtems-rfs-rtems-dev.c: Changed rtems_deviceio_errno() to
cope with a status code of RTEMS_SUCCESSFUL. Removed dependency on
association framework.
Diffstat (limited to 'cpukit/libfs/src/imfs/deviceio.c')
-rw-r--r-- | cpukit/libfs/src/imfs/deviceio.c | 18 |
1 files changed, 4 insertions, 14 deletions
diff --git a/cpukit/libfs/src/imfs/deviceio.c b/cpukit/libfs/src/imfs/deviceio.c index 70cb936425..61d138ae59 100644 --- a/cpukit/libfs/src/imfs/deviceio.c +++ b/cpukit/libfs/src/imfs/deviceio.c @@ -20,17 +20,11 @@ #include <rtems.h> #include <rtems/libio.h> -#include <rtems/assoc.h> /* assoc.h not included by rtems.h */ -#include <errno.h> +#include <rtems/devfs.h> #include "imfs.h" /* - * Convert RTEMS status to a UNIX errno - */ -extern int rtems_deviceio_errno(rtems_status_code code); - -/* * device_open * * This handler maps an open() operation onto rtems_io_open(). @@ -58,10 +52,8 @@ int device_open( the_jnode->info.device.minor, (void *) &args ); - if ( status ) - return rtems_deviceio_errno(status); - return 0; + return rtems_deviceio_errno( status ); } /* @@ -89,10 +81,8 @@ int device_close( the_jnode->info.device.minor, (void *) &args ); - if ( status ) { - return rtems_deviceio_errno(status); - } - return 0; + + return rtems_deviceio_errno( status ); } /* |