Changeset 51435fc7 in rtems


Ignore:
Timestamp:
Oct 12, 1999, 7:26:37 PM (22 years ago)
Author:
Joel Sherrill <joel.sherrill@…>
Branches:
4.10, 4.11, 4.8, 4.9, 5, master
Children:
a6883c4
Parents:
dd0f326
Message:

Split null handlers table to own file and renamed.

Renamed IMFS handler tables to include IMFS prefix.

Files:
26 edited

Legend:

Unmodified
Added
Removed
  • c/src/exec/include/rtems/libio_.h

    rdd0f326 r51435fc7  
    5454#define RTEMS_LIBIO_IOP_SEM(n)  rtems_build_name('L', 'B', 'I', n)
    5555
    56 extern rtems_id        rtems_libio_semaphore;
     56extern rtems_id                          rtems_libio_semaphore;
     57extern rtems_filesystem_file_handlers_r  rtems_filesystem_null_handlers;
    5758
    5859/*
  • c/src/exec/libcsupport/include/rtems/libio_.h

    rdd0f326 r51435fc7  
    5454#define RTEMS_LIBIO_IOP_SEM(n)  rtems_build_name('L', 'B', 'I', n)
    5555
    56 extern rtems_id        rtems_libio_semaphore;
     56extern rtems_id                          rtems_libio_semaphore;
     57extern rtems_filesystem_file_handlers_r  rtems_filesystem_null_handlers;
    5758
    5859/*
  • c/src/exec/libcsupport/src/fs_null_handlers.c

    rdd0f326 r51435fc7  
    11/*
    2  *  Operations Tables for the IMFS
     2 *  Null Filesystem Operations Tables
    33 *
    44 *  COPYRIGHT (c) 1989-1998.
     
    1515#include <errno.h>
    1616
    17 #include "imfs.h"
    18 
    19 /*
    20  *  Set of operations handlers for operations on memfile entities.
    21  */
    22 
    23 rtems_filesystem_file_handlers_r memfile_handlers = {
    24   memfile_open,
    25   memfile_close,
    26   memfile_read,
    27   memfile_write,
    28   memfile_ioctl,
    29   memfile_lseek,
    30   IMFS_stat,
    31   IMFS_fchmod,
    32   memfile_ftruncate,
    33   NULL,                /* fpathconf */
    34   NULL,                /* fsync */
    35   IMFS_fdatasync,
    36   IMFS_fcntl
    37 };
    38 
    39 /*
    40  *  Set of operations handlers for operations on directories.
    41  */
    42 
    43 rtems_filesystem_file_handlers_r dir_handlers = {
    44   imfs_dir_open,
    45   imfs_dir_close,
    46   imfs_dir_read,
    47   NULL,             /* write */
    48   NULL,             /* ioctl */
    49   imfs_dir_lseek,
    50   imfs_dir_fstat,
    51   IMFS_fchmod,
    52   NULL,             /* ftruncate */
    53   NULL,             /* fpathconf */
    54   NULL,             /* fsync */
    55   IMFS_fdatasync,
    56   IMFS_fcntl
    57 };
    58 
    59 /*
    60  *  Handler table for IMFS device nodes
    61  */
    62 
    63 rtems_filesystem_file_handlers_r device_handlers = {
    64   device_open,
    65   device_close,
    66   device_read,
    67   device_write,
    68   device_ioctl,
    69   device_lseek,
    70   IMFS_stat,
    71   IMFS_fchmod,
    72   NULL,   /* ftruncate */
    73   NULL,   /* fpathconf */
    74   NULL,   /* fsync */
    75   NULL,   /* fdatasync */
    76   NULL    /* fcntl */
    77 };
     17#include <rtems/libio.h>
    7818
    7919/*
     
    8121 */
    8222
    83 rtems_filesystem_file_handlers_r null_handlers = {
     23rtems_filesystem_file_handlers_r rtems_filesystem_null_handlers = {
    8424  NULL,       /* open */
    8525  NULL,       /* close */
  • c/src/exec/libfs/src/imfs/imfs.h

    rdd0f326 r51435fc7  
    211211 */
    212212
    213 extern rtems_filesystem_file_handlers_r       device_handlers;
    214 extern rtems_filesystem_file_handlers_r       memfile_handlers;
    215 extern rtems_filesystem_file_handlers_r       dir_handlers;
    216 extern rtems_filesystem_file_handlers_r       null_handlers;
     213extern rtems_filesystem_file_handlers_r       IMFS_device_handlers;
     214extern rtems_filesystem_file_handlers_r       IMFS_memfile_handlers;
     215extern rtems_filesystem_file_handlers_r       IMFS_directory_handlers;
    217216extern rtems_filesystem_operations_table      IMFS_ops;
    218217extern rtems_filesystem_limits_and_options_t  IMFS_LIMITS_AND_OPTIONS;
  • c/src/exec/libfs/src/imfs/imfs_eval.c

    rdd0f326 r51435fc7  
    3737  switch( node->type ) {
    3838    case IMFS_DIRECTORY:
    39       loc->handlers = &dir_handlers;
     39      loc->handlers = &IMFS_directory_handlers;
    4040      break;
    4141    case IMFS_DEVICE:
    42       loc->handlers = &device_handlers;
     42      loc->handlers = &IMFS_device_handlers;
    4343      break;
    4444    case IMFS_SYM_LINK:
    4545    case IMFS_HARD_LINK:
    46       loc->handlers = &null_handlers;
     46      loc->handlers = &rtems_filesystem_null_handlers;
    4747      break;
    4848    case IMFS_MEMORY_FILE:
    49       loc->handlers = &memfile_handlers;
     49      loc->handlers = &IMFS_memfile_handlers;
    5050      break;
    5151  }
  • c/src/exec/libfs/src/imfs/imfs_init.c

    rdd0f326 r51435fc7  
    7474  );
    7575
    76   temp_mt_entry->mt_fs_root.handlers    = &dir_handlers;
     76  temp_mt_entry->mt_fs_root.handlers    = &IMFS_directory_handlers;
    7777  temp_mt_entry->mt_fs_root.ops         = &IMFS_ops;
    7878  temp_mt_entry->pathconf_limits_and_options = IMFS_LIMITS_AND_OPTIONS;
  • c/src/exec/libfs/src/imfs/imfs_initsupp.c

    rdd0f326 r51435fc7  
    7474  );
    7575
    76   temp_mt_entry->mt_fs_root.handlers    = &dir_handlers;
     76  temp_mt_entry->mt_fs_root.handlers    = &IMFS_directory_handlers;
    7777  temp_mt_entry->mt_fs_root.ops         = &IMFS_ops;
    7878  temp_mt_entry->pathconf_limits_and_options = IMFS_LIMITS_AND_OPTIONS;
  • c/src/lib/include/rtems/libio_.h

    rdd0f326 r51435fc7  
    5454#define RTEMS_LIBIO_IOP_SEM(n)  rtems_build_name('L', 'B', 'I', n)
    5555
    56 extern rtems_id        rtems_libio_semaphore;
     56extern rtems_id                          rtems_libio_semaphore;
     57extern rtems_filesystem_file_handlers_r  rtems_filesystem_null_handlers;
    5758
    5859/*
  • c/src/lib/libc/fs_null_handlers.c

    rdd0f326 r51435fc7  
    11/*
    2  *  Operations Tables for the IMFS
     2 *  Null Filesystem Operations Tables
    33 *
    44 *  COPYRIGHT (c) 1989-1998.
     
    1515#include <errno.h>
    1616
    17 #include "imfs.h"
    18 
    19 /*
    20  *  Set of operations handlers for operations on memfile entities.
    21  */
    22 
    23 rtems_filesystem_file_handlers_r memfile_handlers = {
    24   memfile_open,
    25   memfile_close,
    26   memfile_read,
    27   memfile_write,
    28   memfile_ioctl,
    29   memfile_lseek,
    30   IMFS_stat,
    31   IMFS_fchmod,
    32   memfile_ftruncate,
    33   NULL,                /* fpathconf */
    34   NULL,                /* fsync */
    35   IMFS_fdatasync,
    36   IMFS_fcntl
    37 };
    38 
    39 /*
    40  *  Set of operations handlers for operations on directories.
    41  */
    42 
    43 rtems_filesystem_file_handlers_r dir_handlers = {
    44   imfs_dir_open,
    45   imfs_dir_close,
    46   imfs_dir_read,
    47   NULL,             /* write */
    48   NULL,             /* ioctl */
    49   imfs_dir_lseek,
    50   imfs_dir_fstat,
    51   IMFS_fchmod,
    52   NULL,             /* ftruncate */
    53   NULL,             /* fpathconf */
    54   NULL,             /* fsync */
    55   IMFS_fdatasync,
    56   IMFS_fcntl
    57 };
    58 
    59 /*
    60  *  Handler table for IMFS device nodes
    61  */
    62 
    63 rtems_filesystem_file_handlers_r device_handlers = {
    64   device_open,
    65   device_close,
    66   device_read,
    67   device_write,
    68   device_ioctl,
    69   device_lseek,
    70   IMFS_stat,
    71   IMFS_fchmod,
    72   NULL,   /* ftruncate */
    73   NULL,   /* fpathconf */
    74   NULL,   /* fsync */
    75   NULL,   /* fdatasync */
    76   NULL    /* fcntl */
    77 };
     17#include <rtems/libio.h>
    7818
    7919/*
     
    8121 */
    8222
    83 rtems_filesystem_file_handlers_r null_handlers = {
     23rtems_filesystem_file_handlers_r rtems_filesystem_null_handlers = {
    8424  NULL,       /* open */
    8525  NULL,       /* close */
  • c/src/lib/libc/imfs.h

    rdd0f326 r51435fc7  
    211211 */
    212212
    213 extern rtems_filesystem_file_handlers_r       device_handlers;
    214 extern rtems_filesystem_file_handlers_r       memfile_handlers;
    215 extern rtems_filesystem_file_handlers_r       dir_handlers;
    216 extern rtems_filesystem_file_handlers_r       null_handlers;
     213extern rtems_filesystem_file_handlers_r       IMFS_device_handlers;
     214extern rtems_filesystem_file_handlers_r       IMFS_memfile_handlers;
     215extern rtems_filesystem_file_handlers_r       IMFS_directory_handlers;
    217216extern rtems_filesystem_operations_table      IMFS_ops;
    218217extern rtems_filesystem_limits_and_options_t  IMFS_LIMITS_AND_OPTIONS;
  • c/src/lib/libc/imfs_eval.c

    rdd0f326 r51435fc7  
    3737  switch( node->type ) {
    3838    case IMFS_DIRECTORY:
    39       loc->handlers = &dir_handlers;
     39      loc->handlers = &IMFS_directory_handlers;
    4040      break;
    4141    case IMFS_DEVICE:
    42       loc->handlers = &device_handlers;
     42      loc->handlers = &IMFS_device_handlers;
    4343      break;
    4444    case IMFS_SYM_LINK:
    4545    case IMFS_HARD_LINK:
    46       loc->handlers = &null_handlers;
     46      loc->handlers = &rtems_filesystem_null_handlers;
    4747      break;
    4848    case IMFS_MEMORY_FILE:
    49       loc->handlers = &memfile_handlers;
     49      loc->handlers = &IMFS_memfile_handlers;
    5050      break;
    5151  }
  • c/src/lib/libc/imfs_handlers.c

    rdd0f326 r51435fc7  
    2121 */
    2222
    23 rtems_filesystem_file_handlers_r memfile_handlers = {
     23rtems_filesystem_file_handlers_r IMFS_memfile_handlers = {
    2424  memfile_open,
    2525  memfile_close,
     
    4141 */
    4242
    43 rtems_filesystem_file_handlers_r dir_handlers = {
     43rtems_filesystem_file_handlers_r IMFS_directory_handlers = {
    4444  imfs_dir_open,
    4545  imfs_dir_close,
     
    6161 */
    6262
    63 rtems_filesystem_file_handlers_r device_handlers = {
     63rtems_filesystem_file_handlers_r IMFS_device_handlers = {
    6464  device_open,
    6565  device_close,
  • c/src/lib/libc/imfs_init.c

    rdd0f326 r51435fc7  
    7474  );
    7575
    76   temp_mt_entry->mt_fs_root.handlers    = &dir_handlers;
     76  temp_mt_entry->mt_fs_root.handlers    = &IMFS_directory_handlers;
    7777  temp_mt_entry->mt_fs_root.ops         = &IMFS_ops;
    7878  temp_mt_entry->pathconf_limits_and_options = IMFS_LIMITS_AND_OPTIONS;
  • c/src/lib/libc/imfs_initsupp.c

    rdd0f326 r51435fc7  
    7474  );
    7575
    76   temp_mt_entry->mt_fs_root.handlers    = &dir_handlers;
     76  temp_mt_entry->mt_fs_root.handlers    = &IMFS_directory_handlers;
    7777  temp_mt_entry->mt_fs_root.ops         = &IMFS_ops;
    7878  temp_mt_entry->pathconf_limits_and_options = IMFS_LIMITS_AND_OPTIONS;
  • c/src/lib/libc/libio_.h

    rdd0f326 r51435fc7  
    5454#define RTEMS_LIBIO_IOP_SEM(n)  rtems_build_name('L', 'B', 'I', n)
    5555
    56 extern rtems_id        rtems_libio_semaphore;
     56extern rtems_id                          rtems_libio_semaphore;
     57extern rtems_filesystem_file_handlers_r  rtems_filesystem_null_handlers;
    5758
    5859/*
  • c/src/libfs/src/imfs/imfs.h

    rdd0f326 r51435fc7  
    211211 */
    212212
    213 extern rtems_filesystem_file_handlers_r       device_handlers;
    214 extern rtems_filesystem_file_handlers_r       memfile_handlers;
    215 extern rtems_filesystem_file_handlers_r       dir_handlers;
    216 extern rtems_filesystem_file_handlers_r       null_handlers;
     213extern rtems_filesystem_file_handlers_r       IMFS_device_handlers;
     214extern rtems_filesystem_file_handlers_r       IMFS_memfile_handlers;
     215extern rtems_filesystem_file_handlers_r       IMFS_directory_handlers;
    217216extern rtems_filesystem_operations_table      IMFS_ops;
    218217extern rtems_filesystem_limits_and_options_t  IMFS_LIMITS_AND_OPTIONS;
  • c/src/libfs/src/imfs/imfs_eval.c

    rdd0f326 r51435fc7  
    3737  switch( node->type ) {
    3838    case IMFS_DIRECTORY:
    39       loc->handlers = &dir_handlers;
     39      loc->handlers = &IMFS_directory_handlers;
    4040      break;
    4141    case IMFS_DEVICE:
    42       loc->handlers = &device_handlers;
     42      loc->handlers = &IMFS_device_handlers;
    4343      break;
    4444    case IMFS_SYM_LINK:
    4545    case IMFS_HARD_LINK:
    46       loc->handlers = &null_handlers;
     46      loc->handlers = &rtems_filesystem_null_handlers;
    4747      break;
    4848    case IMFS_MEMORY_FILE:
    49       loc->handlers = &memfile_handlers;
     49      loc->handlers = &IMFS_memfile_handlers;
    5050      break;
    5151  }
  • c/src/libfs/src/imfs/imfs_init.c

    rdd0f326 r51435fc7  
    7474  );
    7575
    76   temp_mt_entry->mt_fs_root.handlers    = &dir_handlers;
     76  temp_mt_entry->mt_fs_root.handlers    = &IMFS_directory_handlers;
    7777  temp_mt_entry->mt_fs_root.ops         = &IMFS_ops;
    7878  temp_mt_entry->pathconf_limits_and_options = IMFS_LIMITS_AND_OPTIONS;
  • c/src/libfs/src/imfs/imfs_initsupp.c

    rdd0f326 r51435fc7  
    7474  );
    7575
    76   temp_mt_entry->mt_fs_root.handlers    = &dir_handlers;
     76  temp_mt_entry->mt_fs_root.handlers    = &IMFS_directory_handlers;
    7777  temp_mt_entry->mt_fs_root.ops         = &IMFS_ops;
    7878  temp_mt_entry->pathconf_limits_and_options = IMFS_LIMITS_AND_OPTIONS;
  • cpukit/include/rtems/libio_.h

    rdd0f326 r51435fc7  
    5454#define RTEMS_LIBIO_IOP_SEM(n)  rtems_build_name('L', 'B', 'I', n)
    5555
    56 extern rtems_id        rtems_libio_semaphore;
     56extern rtems_id                          rtems_libio_semaphore;
     57extern rtems_filesystem_file_handlers_r  rtems_filesystem_null_handlers;
    5758
    5859/*
  • cpukit/libcsupport/include/rtems/libio_.h

    rdd0f326 r51435fc7  
    5454#define RTEMS_LIBIO_IOP_SEM(n)  rtems_build_name('L', 'B', 'I', n)
    5555
    56 extern rtems_id        rtems_libio_semaphore;
     56extern rtems_id                          rtems_libio_semaphore;
     57extern rtems_filesystem_file_handlers_r  rtems_filesystem_null_handlers;
    5758
    5859/*
  • cpukit/libcsupport/src/fs_null_handlers.c

    rdd0f326 r51435fc7  
    11/*
    2  *  Operations Tables for the IMFS
     2 *  Null Filesystem Operations Tables
    33 *
    44 *  COPYRIGHT (c) 1989-1998.
     
    1515#include <errno.h>
    1616
    17 #include "imfs.h"
    18 
    19 /*
    20  *  Set of operations handlers for operations on memfile entities.
    21  */
    22 
    23 rtems_filesystem_file_handlers_r memfile_handlers = {
    24   memfile_open,
    25   memfile_close,
    26   memfile_read,
    27   memfile_write,
    28   memfile_ioctl,
    29   memfile_lseek,
    30   IMFS_stat,
    31   IMFS_fchmod,
    32   memfile_ftruncate,
    33   NULL,                /* fpathconf */
    34   NULL,                /* fsync */
    35   IMFS_fdatasync,
    36   IMFS_fcntl
    37 };
    38 
    39 /*
    40  *  Set of operations handlers for operations on directories.
    41  */
    42 
    43 rtems_filesystem_file_handlers_r dir_handlers = {
    44   imfs_dir_open,
    45   imfs_dir_close,
    46   imfs_dir_read,
    47   NULL,             /* write */
    48   NULL,             /* ioctl */
    49   imfs_dir_lseek,
    50   imfs_dir_fstat,
    51   IMFS_fchmod,
    52   NULL,             /* ftruncate */
    53   NULL,             /* fpathconf */
    54   NULL,             /* fsync */
    55   IMFS_fdatasync,
    56   IMFS_fcntl
    57 };
    58 
    59 /*
    60  *  Handler table for IMFS device nodes
    61  */
    62 
    63 rtems_filesystem_file_handlers_r device_handlers = {
    64   device_open,
    65   device_close,
    66   device_read,
    67   device_write,
    68   device_ioctl,
    69   device_lseek,
    70   IMFS_stat,
    71   IMFS_fchmod,
    72   NULL,   /* ftruncate */
    73   NULL,   /* fpathconf */
    74   NULL,   /* fsync */
    75   NULL,   /* fdatasync */
    76   NULL    /* fcntl */
    77 };
     17#include <rtems/libio.h>
    7818
    7919/*
     
    8121 */
    8222
    83 rtems_filesystem_file_handlers_r null_handlers = {
     23rtems_filesystem_file_handlers_r rtems_filesystem_null_handlers = {
    8424  NULL,       /* open */
    8525  NULL,       /* close */
  • cpukit/libfs/src/imfs/imfs.h

    rdd0f326 r51435fc7  
    211211 */
    212212
    213 extern rtems_filesystem_file_handlers_r       device_handlers;
    214 extern rtems_filesystem_file_handlers_r       memfile_handlers;
    215 extern rtems_filesystem_file_handlers_r       dir_handlers;
    216 extern rtems_filesystem_file_handlers_r       null_handlers;
     213extern rtems_filesystem_file_handlers_r       IMFS_device_handlers;
     214extern rtems_filesystem_file_handlers_r       IMFS_memfile_handlers;
     215extern rtems_filesystem_file_handlers_r       IMFS_directory_handlers;
    217216extern rtems_filesystem_operations_table      IMFS_ops;
    218217extern rtems_filesystem_limits_and_options_t  IMFS_LIMITS_AND_OPTIONS;
  • cpukit/libfs/src/imfs/imfs_eval.c

    rdd0f326 r51435fc7  
    3737  switch( node->type ) {
    3838    case IMFS_DIRECTORY:
    39       loc->handlers = &dir_handlers;
     39      loc->handlers = &IMFS_directory_handlers;
    4040      break;
    4141    case IMFS_DEVICE:
    42       loc->handlers = &device_handlers;
     42      loc->handlers = &IMFS_device_handlers;
    4343      break;
    4444    case IMFS_SYM_LINK:
    4545    case IMFS_HARD_LINK:
    46       loc->handlers = &null_handlers;
     46      loc->handlers = &rtems_filesystem_null_handlers;
    4747      break;
    4848    case IMFS_MEMORY_FILE:
    49       loc->handlers = &memfile_handlers;
     49      loc->handlers = &IMFS_memfile_handlers;
    5050      break;
    5151  }
  • cpukit/libfs/src/imfs/imfs_init.c

    rdd0f326 r51435fc7  
    7474  );
    7575
    76   temp_mt_entry->mt_fs_root.handlers    = &dir_handlers;
     76  temp_mt_entry->mt_fs_root.handlers    = &IMFS_directory_handlers;
    7777  temp_mt_entry->mt_fs_root.ops         = &IMFS_ops;
    7878  temp_mt_entry->pathconf_limits_and_options = IMFS_LIMITS_AND_OPTIONS;
  • cpukit/libfs/src/imfs/imfs_initsupp.c

    rdd0f326 r51435fc7  
    7474  );
    7575
    76   temp_mt_entry->mt_fs_root.handlers    = &dir_handlers;
     76  temp_mt_entry->mt_fs_root.handlers    = &IMFS_directory_handlers;
    7777  temp_mt_entry->mt_fs_root.ops         = &IMFS_ops;
    7878  temp_mt_entry->pathconf_limits_and_options = IMFS_LIMITS_AND_OPTIONS;
Note: See TracChangeset for help on using the changeset viewer.