Ignore:
Timestamp:
May 14, 2012, 1:19:20 PM (8 years ago)
Author:
Sebastian Huber <sebastian.huber@…>
Branches:
4.11, master
Children:
53da07e
Parents:
df01da67
git-author:
Sebastian Huber <sebastian.huber@…> (05/14/12 13:19:20)
git-committer:
Sebastian Huber <sebastian.huber@…> (05/15/12 08:01:42)
Message:

Filesystem: Add shared device IO support

The device IO file system support in IMFS, devFS, and RFS uses now a
shared implementation.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • cpukit/libfs/src/devfs/devread.c

    rdf01da67 rfed66f99  
    66
    77#if HAVE_CONFIG_H
    8 #include "config.h"
     8  #include "config.h"
    99#endif
    1010
    11 #include <rtems.h>
    12 #include <rtems/io.h>
     11#include "devfs.h"
    1312
    14 #include "devfs.h"
     13#include <rtems/deviceio.h>
    1514
    1615ssize_t devFS_read(
     
    2019)
    2120{
    22   rtems_libio_rw_args_t   args;
    23   rtems_status_code       status;
    2421  const devFS_node *np = iop->pathinfo.node_access;
    2522
    26   args.iop         = iop;
    27   args.offset      = iop->offset;
    28   args.buffer      = buffer;
    29   args.count       = count;
    30   args.flags       = iop->flags;
    31   args.bytes_moved = 0;
    32 
    33   status = rtems_io_read(
    34     np->major,
    35     np->minor,
    36     (void *) &args
    37   );
    38 
    39   if ( status )
    40     return rtems_deviceio_errno(status);
    41 
    42   return (ssize_t) args.bytes_moved;
     23  return rtems_deviceio_read( iop, buffer, count, np->major, np->minor );
    4324}
    44 
Note: See TracChangeset for help on using the changeset viewer.