source: rtems/c/src/exec/libfs/src/imfs/miniimfs_init.c @ 657e1bf6

4.104.114.84.95
Last change on this file since 657e1bf6 was 657e1bf6, checked in by Joel Sherrill <joel.sherrill@…>, on 10/26/99 at 20:17:13

Added initial cut at miniIMFS which leaves out memfile and directory
readdir support. The next step is to add a mount table and configure
either the miniIMFS or the full IMFS at the application level.

  • Property mode set to 100644
File size: 1.5 KB
Line 
1/*
2 *  Mini-IMFS Initialization
3 *
4 *  COPYRIGHT (c) 1989-1998.
5 *  On-Line Applications Research Corporation (OAR).
6 *  Copyright assigned to U.S. Government, 1994.
7 *
8 *  The license and distribution terms for this file may be
9 *  found in the file LICENSE in this distribution or at
10 *  http://www.OARcorp.com/rtems/license.html.
11 *
12 *  $Id$
13 */
14
15#include <sys/types.h>         /* for mkdir */
16#include <fcntl.h>
17#include <unistd.h>
18#include <stdlib.h>
19
20#include <assert.h>
21
22#include "imfs.h"
23#include "libio_.h"
24
25#if defined(IMFS_DEBUG)
26#include <stdio.h>
27#endif
28
29/*
30 *  miniIMFS file system operations table
31 */
32
33rtems_filesystem_operations_table  miniIMFS_ops = {
34  IMFS_eval_path,
35  IMFS_evaluate_for_make,
36  NULL, /* XXX IMFS_link, */
37  NULL, /* XXX IMFS_unlink, */
38  IMFS_node_type,
39  IMFS_mknod,
40  NULL, /* XXX IMFS_rmnod, */
41  NULL, /* XXX IMFS_chown, */
42  NULL, /* XXX IMFS_freenodinfo, */
43  NULL, /* XXX IMFS_mount, */
44  miniIMFS_initialize,
45  NULL, /* XXX IMFS_unmount, */
46  NULL, /* XXX IMFS_fsunmount, */
47  NULL, /* XXX IMFS_utime, */
48  NULL, /* XXX IMFS_evaluate_link, */
49  NULL, /* XXX IMFS_symlink, */
50  NULL  /* XXX IMFS_readlink */
51};
52
53/*
54 *  miniIMFS_initialize
55 */
56
57int miniIMFS_initialize(
58  rtems_filesystem_mount_table_entry_t *temp_mt_entry
59)
60{
61   IMFS_initialize_support(
62      temp_mt_entry,
63      &miniIMFS_ops,
64      &rtems_filesystem_null_handlers,  /* for memfiles */
65      &rtems_filesystem_null_handlers   /* for directories */
66   );
67   return 0;
68}
69
70
71
Note: See TracBrowser for help on using the repository browser.