Changeset df01da67 in rtems


Ignore:
Timestamp:
May 14, 2012, 11:16:31 AM (7 years ago)
Author:
Sebastian Huber <sebastian.huber@…>
Branches:
4.11, master
Children:
fed66f99
Parents:
a1c6b96a
git-author:
Sebastian Huber <sebastian.huber@…> (05/14/12 11:16:31)
git-committer:
Sebastian Huber <sebastian.huber@…> (05/15/12 08:01:42)
Message:

Filesystem: Use ioctl_command_t

Files:
16 edited

Legend:

Unmodified
Added
Removed
  • cpukit/libcsupport/include/rtems/libio.h

    ra1c6b96a rdf01da67  
    833833 */
    834834typedef int (*rtems_filesystem_ioctl_t)(
    835   rtems_libio_t *iop,
    836   uint32_t       request,
    837   void          *buffer
     835  rtems_libio_t   *iop,
     836  ioctl_command_t  request,
     837  void            *buffer
    838838);
    839839
     
    10091009 */
    10101010int rtems_filesystem_default_ioctl(
    1011   rtems_libio_t *iop,
    1012   uint32_t       command,
    1013   void          *buffer
     1011  rtems_libio_t   *iop,
     1012  ioctl_command_t  request,
     1013  void            *buffer
    10141014);
    10151015
     
    12261226typedef struct {
    12271227  rtems_libio_t          *iop;
    1228   uint32_t                command;
     1228  ioctl_command_t         command;
    12291229  void                   *buffer;
    12301230  int                     ioctl_return;
  • cpukit/libcsupport/include/sys/ioccom.h

    ra1c6b96a rdf01da67  
    8484#define FIOGETOWN       _IOR('f', 123, int)     /* get owner */
    8585
     86typedef uint32_t ioctl_command_t;
     87
    8688#ifndef _KERNEL
    8789
    8890#include <sys/cdefs.h>
    89 
    90 #ifndef __ioctl_command_defined
    91 typedef u_int32_t ioctl_command_t;
    92 #define __ioctl_command_defined
    93 #endif
    9491
    9592__BEGIN_DECLS
  • cpukit/libfs/src/defaults/default_ioctl.c

    ra1c6b96a rdf01da67  
    88 */
    99
    10 #include <rtems/libio.h>
     10#if HAVE_CONFIG_H
     11  #include "config.h"
     12#endif
     13
    1114#include <rtems/libio_.h>
    12 #include <rtems/seterr.h>
    1315
    1416int rtems_filesystem_default_ioctl(
    15   rtems_libio_t *iop,
    16   uint32_t       command,
    17   void          *buffer
     17  rtems_libio_t   *iop,
     18  ioctl_command_t  request,
     19  void            *buffer
    1820)
    1921{
  • cpukit/libfs/src/devfs/devfs.h

    ra1c6b96a rdf01da67  
    138138
    139139extern int devFS_ioctl(
    140   rtems_libio_t *iop,
    141   uint32_t       command,
    142   void          *buffer
     140  rtems_libio_t   *iop,
     141  ioctl_command_t  command,
     142  void            *buffer
    143143);
    144144
  • cpukit/libfs/src/devfs/devioctl.c

    ra1c6b96a rdf01da67  
    1515
    1616int devFS_ioctl(
    17   rtems_libio_t *iop,
    18   uint32_t       command,
    19   void          *buffer
     17  rtems_libio_t   *iop,
     18  ioctl_command_t  command,
     19  void            *buffer
    2020)
    2121{
  • cpukit/libfs/src/imfs/deviceio.c

    ra1c6b96a rdf01da67  
    163163
    164164int device_ioctl(
    165   rtems_libio_t *iop,
    166   uint32_t       command,
    167   void          *buffer
     165  rtems_libio_t   *iop,
     166  ioctl_command_t  command,
     167  void            *buffer
    168168)
    169169{
  • cpukit/libfs/src/imfs/imfs.h

    ra1c6b96a rdf01da67  
    436436);
    437437
    438 extern int memfile_ioctl(
    439   rtems_libio_t *iop,             /* IN  */
    440   uint32_t       command,         /* IN  */
    441   void          *buffer           /* IN  */
    442 );
    443 
    444438extern int device_open(
    445439  rtems_libio_t *iop,            /* IN  */
     
    466460
    467461extern int device_ioctl(
    468   rtems_libio_t *iop,               /* IN  */
    469   uint32_t       command,           /* IN  */
    470   void          *buffer             /* IN  */
     462  rtems_libio_t   *iop,
     463  ioctl_command_t  command,
     464  void            *buffer
    471465);
    472466
  • cpukit/libfs/src/imfs/imfs_fifo.c

    ra1c6b96a rdf01da67  
    8484
    8585static int IMFS_fifo_ioctl(
    86   rtems_libio_t *iop,
    87   uint32_t       command,
    88   void          *buffer
     86  rtems_libio_t   *iop,
     87  ioctl_command_t  command,
     88  void            *buffer
    8989)
    9090{
  • cpukit/libfs/src/imfs/imfs_handlers_memfile.c

    ra1c6b96a rdf01da67  
    3434  memfile_read,
    3535  memfile_write,
    36   memfile_ioctl,
     36  rtems_filesystem_default_ioctl,
    3737  rtems_filesystem_default_lseek_file,
    3838  IMFS_stat_file,
  • cpukit/libfs/src/imfs/memfile.c

    ra1c6b96a rdf01da67  
    150150
    151151  return status;
    152 }
    153 
    154 /*
    155  *  memfile_ioctl
    156  *
    157  *  This routine processes the ioctl() system call.
    158  *
    159  *  NOTE:  No ioctl()'s are supported for in-memory files.
    160  */
    161 int memfile_ioctl(
    162   rtems_libio_t *iop,
    163   uint32_t       command,
    164   void          *buffer
    165 )
    166 {
    167   return 0;
    168152}
    169153
  • cpukit/libfs/src/pipe/fifo.c

    ra1c6b96a rdf01da67  
    550550 */
    551551int pipe_ioctl(
    552   pipe_control_t *pipe,
    553   uint32_t        cmd,
    554   void           *buffer,
    555   rtems_libio_t  *iop
     552  pipe_control_t  *pipe,
     553  ioctl_command_t  cmd,
     554  void            *buffer,
     555  rtems_libio_t   *iop
    556556)
    557557{
  • cpukit/libfs/src/pipe/pipe.h

    ra1c6b96a rdf01da67  
    9797 */
    9898extern int pipe_ioctl(
    99   pipe_control_t *pipe,
    100   uint32_t        cmd,
    101   void           *buffer,
    102   rtems_libio_t  *iop
     99  pipe_control_t  *pipe,
     100  ioctl_command_t  cmd,
     101  void            *buffer,
     102  rtems_libio_t   *iop
    103103);
    104104
  • cpukit/libfs/src/rfs/rtems-rfs-rtems-dev.c

    ra1c6b96a rdf01da67  
    195195
    196196static int
    197 rtems_rfs_rtems_device_ioctl (rtems_libio_t* iop,
    198                               uint32_t      command,
    199                               void*          buffer)
     197rtems_rfs_rtems_device_ioctl (rtems_libio_t*  iop,
     198                              ioctl_command_t command,
     199                              void*           buffer)
    200200{
    201201  rtems_libio_ioctl_args_t  args;
  • cpukit/libfs/src/rfs/rtems-rfs-rtems-file.c

    ra1c6b96a rdf01da67  
    258258
    259259/**
    260  * This routine processes the ioctl() system call.
    261  *
    262  * @note  No ioctl()'s are currently supported for RFS files.
    263  *
    264  * @param iop
    265  * @param command
    266  * @param buffer
    267  */
    268 
    269 static int
    270 rtems_rfs_rtems_file_ioctl (rtems_libio_t* iop, uint32_t command, void* buffer)
    271 {
    272   return 0;
    273 }
    274 
    275 /**
    276260 * This routine processes the lseek() system call.
    277261 *
     
    352336  .read_h      = rtems_rfs_rtems_file_read,
    353337  .write_h     = rtems_rfs_rtems_file_write,
    354   .ioctl_h     = rtems_rfs_rtems_file_ioctl,
     338  .ioctl_h     = rtems_filesystem_default_ioctl,
    355339  .lseek_h     = rtems_rfs_rtems_file_lseek,
    356340  .fstat_h     = rtems_rfs_rtems_fstat,
  • cpukit/libnetworking/rtems/rtems_bsdnet_internal.h

    ra1c6b96a rdf01da67  
    2323typedef unsigned int            vm_size_t;
    2424
    25 #ifndef __ioctl_command_defined
    26 typedef u_int32_t ioctl_command_t;
    27 #define __ioctl_command_defined
    28 #endif
    29 
    30 
    3125#define _BSD_OFF_T_     int32_t
    3226#define _BSD_PID_T_     rtems_id
     
    3933
    4034#include <sys/time.h>
     35#include <sys/ioctl.h>
    4136
    4237struct mdproc {
  • testsuites/psxtests/psxfile01/test.c

    ra1c6b96a rdf01da67  
    335335  fd = open( "/tmp/john", O_RDWR|O_CREAT, S_IRWXU|S_IRWXG|S_IRWXO );
    336336  rtems_test_assert( fd != -1 );
    337 
    338   puts("tcdrain /tmp/john" );
    339   status = tcdrain( fd );
     337  status = close( fd );
    340338  rtems_test_assert( status == 0 );
    341339
Note: See TracChangeset for help on using the changeset viewer.