RTEMS 7.0-rc1
Loading...
Searching...
No Matches
imfs.h
Go to the documentation of this file.
1/* SPDX-License-Identifier: BSD-2-Clause */
2
9/*
10 * COPYRIGHT (C) 1989, 2021 On-Line Applications Research Corporation (OAR).
11 *
12 * Redistribution and use in source and binary forms, with or without
13 * modification, are permitted provided that the following conditions
14 * are met:
15 * 1. Redistributions of source code must retain the above copyright
16 * notice, this list of conditions and the following disclaimer.
17 * 2. Redistributions in binary form must reproduce the above copyright
18 * notice, this list of conditions and the following disclaimer in the
19 * documentation and/or other materials provided with the distribution.
20 *
21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
22 * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
23 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
24 * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
25 * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
26 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
27 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
28 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
29 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
30 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
31 * POSSIBILITY OF SUCH DAMAGE.
32 */
33
34#ifndef _RTEMS_IMFS_H
35#define _RTEMS_IMFS_H
36
37#include <sys/time.h>
38#include <sys/statvfs.h>
39#include <limits.h>
40
41#include <rtems/libio_.h>
42#include <rtems/pipe.h>
43
53#ifdef __cplusplus
54extern "C" {
55#endif
56
57/*
58 * Data types
59 */
60
61struct IMFS_jnode_tt;
62typedef struct IMFS_jnode_tt IMFS_jnode_t;
63
65extern IMFS_memfile_ops_t imfs_memfile_ops;
66
89#define IMFS_MEMFILE_DEFAULT_BYTES_PER_BLOCK 128
90 extern const size_t imfs_memfile_bytes_per_block;
91
92#define IMFS_MEMFILE_BYTES_PER_BLOCK imfs_memfile_bytes_per_block
93#define IMFS_MEMFILE_BLOCK_SLOTS \
94 (IMFS_MEMFILE_BYTES_PER_BLOCK / sizeof(void *))
95
96typedef uint8_t *block_p;
97typedef block_p *block_ptr;
98
99/*
100 * Important block numbers for "memfiles"
101 */
102#define FIRST_INDIRECT (0)
103#define LAST_INDIRECT (IMFS_MEMFILE_BLOCK_SLOTS - 1)
104
105#define FIRST_DOUBLY_INDIRECT (LAST_INDIRECT + 1)
106#define LAST_DOUBLY_INDIRECT \
107 (LAST_INDIRECT + \
108 (IMFS_MEMFILE_BLOCK_SLOTS * IMFS_MEMFILE_BLOCK_SLOTS))
109
110#define FIRST_TRIPLY_INDIRECT (LAST_DOUBLY_INDIRECT + 1)
111#define LAST_TRIPLY_INDIRECT \
112 (LAST_DOUBLY_INDIRECT +\
113 (IMFS_MEMFILE_BLOCK_SLOTS * \
114 IMFS_MEMFILE_BLOCK_SLOTS * IMFS_MEMFILE_BLOCK_SLOTS))
115
116#define IMFS_MEMFILE_MAXIMUM_SIZE \
117 ((LAST_TRIPLY_INDIRECT + 1) * IMFS_MEMFILE_BYTES_PER_BLOCK)
118
140typedef IMFS_jnode_t *(*IMFS_node_control_initialize)(
141 IMFS_jnode_t *node,
142 void *arg
143);
144
156 IMFS_jnode_t *node,
157 void *arg
158);
159
160IMFS_jnode_t *IMFS_node_initialize_directory(
161 IMFS_jnode_t *node,
162 void *arg
163);
164
177 IMFS_jnode_t *node,
178 void *arg
179);
180
192typedef IMFS_jnode_t *(*IMFS_node_control_remove)(
193 IMFS_jnode_t *node
194);
195
206 IMFS_jnode_t *node
207);
208
209IMFS_jnode_t *IMFS_node_remove_directory( IMFS_jnode_t *node );
210
219
228
237
241typedef struct {
242 const rtems_filesystem_file_handlers_r *handlers;
243 IMFS_node_control_initialize node_initialize;
244 IMFS_node_control_remove node_remove;
245 IMFS_node_control_destroy node_destroy;
247
248typedef struct {
249 IMFS_node_control node_control;
250 size_t node_size;
252
260/*
261 * Maximum length of a "basename" of an IMFS file/node.
262 */
263
264#define IMFS_NAME_MAX _POSIX_NAME_MAX
265
266/*
267
268 * The control structure for an IMFS jnode.
269 */
270
272 rtems_chain_node Node; /* for chaining them together */
273 IMFS_jnode_t *Parent; /* Parent node */
274 const char *name; /* "basename" (not \0 terminated) */
275 uint16_t namelen; /* Length of "basename" */
276 mode_t st_mode; /* File mode */
277 unsigned short reference_count;
278 nlink_t st_nlink; /* Link count */
279
280 uid_t st_uid; /* User ID of owner */
281 gid_t st_gid; /* Group ID of owner */
282
283 time_t stat_atime; /* Time of last access */
284 time_t stat_mtime; /* Time of last modification */
285 time_t stat_ctime; /* Time of last status change */
287};
288
292typedef void *(*IMFS_memfile_allocator)(void);
293
298 void *memory
299);
300
304typedef size_t (*IMFS_memfile_free_space)(void);
305
315 IMFS_memfile_allocator allocate_block;
316 IMFS_memfile_deallocator free_block;
317 IMFS_memfile_free_space get_free_space;
318};
319
326
333
339size_t IMFS_default_free_space(void);
340
341#define IMFS_MEMFILE_DEFAULT_OPS \
342{ \
343 .allocate_block = IMFS_default_allocate_block, \
344 .free_block = IMFS_default_deallocate_block, \
345 .get_free_space = IMFS_default_free_space \
346}
347
348typedef struct {
349 IMFS_jnode_t Node;
350 rtems_chain_control Entries;
353
354typedef struct {
355 IMFS_jnode_t Node;
359
360typedef struct {
361 IMFS_jnode_t Node;
362 IMFS_jnode_t *link_node;
364
365typedef struct {
366 IMFS_jnode_t Node;
367 char *name;
369
370typedef struct {
371 IMFS_jnode_t Node;
372 size_t size; /* size of file in bytes */
374
375typedef struct {
376 IMFS_filebase_t File;
377 block_ptr indirect; /* array of 128 data blocks pointers */
378 block_ptr doubly_indirect; /* 128 indirect blocks */
379 block_ptr triply_indirect; /* 128 doubly indirect blocks */
381
382typedef struct {
383 IMFS_filebase_t File;
384 block_p direct; /* pointer to file image */
386
387/* Support copy on write for linear files */
388typedef union {
389 IMFS_jnode_t Node;
390 IMFS_filebase_t File;
391 IMFS_memfile_t Memfile;
392 IMFS_linearfile_t Linearfile;
394
395typedef struct {
396 IMFS_jnode_t Node;
397 pipe_control_t *pipe;
399
400typedef struct {
401 IMFS_jnode_t Node;
402 void *context;
404
405typedef struct {
406 const void *data;
407 size_t size;
409
410static inline IMFS_jnode_t *IMFS_iop_to_node( const rtems_libio_t *iop )
411{
412 return (IMFS_jnode_t *) iop->pathinfo.node_access;
413}
414
415static inline IMFS_directory_t *IMFS_iop_to_directory(
416 const rtems_libio_t *iop
417)
418{
419 return (IMFS_directory_t *) iop->pathinfo.node_access;
420}
421
422static inline IMFS_device_t *IMFS_iop_to_device( const rtems_libio_t *iop )
423{
424 return (IMFS_device_t *) iop->pathinfo.node_access;
425}
426
427static inline IMFS_file_t *IMFS_iop_to_file( const rtems_libio_t *iop )
428{
429 return (IMFS_file_t *) iop->pathinfo.node_access;
430}
431
432static inline IMFS_memfile_t *IMFS_iop_to_memfile( const rtems_libio_t *iop )
433{
434 return (IMFS_memfile_t *) iop->pathinfo.node_access;
435}
436
437typedef struct {
438 const IMFS_mknod_control *directory;
439 const IMFS_mknod_control *device;
440 const IMFS_mknod_control *file;
441 const IMFS_mknod_control *fifo;
443
444typedef struct {
445 IMFS_directory_t Root_directory;
446 const IMFS_mknod_controls *mknod_controls;
447 int jnode_count;
449
450typedef struct {
451 IMFS_fs_info_t *fs_info;
453 const IMFS_mknod_controls *mknod_controls;
455
456/*
457 * Shared Data
458 */
459
460extern const IMFS_mknod_control IMFS_mknod_control_dir_default;
461extern const IMFS_mknod_control IMFS_mknod_control_dir_minimal;
462extern const IMFS_mknod_control IMFS_mknod_control_device;
463extern const IMFS_mknod_control IMFS_mknod_control_memfile;
464extern const IMFS_node_control IMFS_node_control_linfile;
465extern const IMFS_mknod_control IMFS_mknod_control_fifo;
466extern const IMFS_mknod_control IMFS_mknod_control_enosys;
467
468extern const rtems_filesystem_limits_and_options_t IMFS_LIMITS_AND_OPTIONS;
469
470/*
471 * Routines
472 */
473
474extern int IMFS_initialize(
476 const void *data
477);
478
479extern int IMFS_initialize_support(
481 const void *data
482);
483
487extern void IMFS_fsunmount(
489);
490
542extern int rtems_tarfs_load(
543 const char *mountpoint,
544 const void *tar_image,
545 size_t tar_size
546);
547
551extern void IMFS_node_destroy( IMFS_jnode_t *node );
552
557
561extern void IMFS_node_free( const rtems_filesystem_location_info_t *loc );
562
568extern int IMFS_stat(
570 struct stat *buf
571);
572
573extern int IMFS_stat_file(
575 struct stat *buf
576);
577
581extern void IMFS_eval_path(
583);
584
588extern void IMFS_eval_path_devfs(
590);
591
599extern int IMFS_link(
600 const rtems_filesystem_location_info_t *parentloc,
601 const rtems_filesystem_location_info_t *targetloc,
602 const char *name,
603 size_t namelen
604);
605
612extern int IMFS_chown(
614 uid_t owner,
615 gid_t group
616);
617
623extern int IMFS_mknod(
624 const rtems_filesystem_location_info_t *parentloc,
625 const char *name,
626 size_t namelen,
627 mode_t mode,
628 dev_t dev
629);
630
631extern IMFS_jnode_t *IMFS_initialize_node(
632 IMFS_jnode_t *node,
633 const IMFS_node_control *node_control,
634 const char *name,
635 size_t namelen,
636 mode_t mode,
637 void *arg
638);
639
647 const rtems_filesystem_location_info_t *parentloc,
648 const IMFS_node_control *node_control,
649 size_t node_size,
650 const char *name,
651 size_t namelen,
652 mode_t mode,
653 void *arg
654);
655
656static inline bool IMFS_is_imfs_instance(
658)
659{
660 return loc->mt_entry->ops->clonenod_h == IMFS_node_clone;
661}
662
670#define IMFS_NODE_CONTROL_INITIALIZER( handlers, init, destroy ) \
671 { \
672 ( handlers ), \
673 ( init ), \
674 IMFS_node_remove_default, \
675 ( destroy ) \
676 }
677
690#define IMFS_NODE_INITIALIZER( node_control, name, namelen, mode ) \
691 { \
692 { NULL, NULL }, \
693 NULL, \
694 ( name ), \
695 ( namelen ), \
696 ( mode ), \
697 0, \
698 0, \
699 0, \
700 0, \
701 0, \
702 0, \
703 0, \
704 ( node_control ) \
705 }
706
720static inline void IMFS_node_preinitialize(
721 IMFS_jnode_t *node,
722 const IMFS_node_control *node_control,
723 const char *name,
724 size_t namelen,
725 mode_t mode
726)
727{
728 node->control = node_control;
729 node->name = name;
730 node->namelen = namelen;
731 node->st_mode = mode;
732}
733
747int IMFS_add_node( const char *path, IMFS_jnode_t *node, void *arg );
748
749extern int IMFS_make_node(
750 const char *path,
751 mode_t mode,
752 const IMFS_node_control *node_control,
753 size_t node_size,
754 void *context
755);
756
768extern int IMFS_make_linearfile(
769 const char *path,
770 mode_t mode,
771 const void *data,
772 size_t size
773);
774
793/* Provided for backward compatibility */
794#define IMFS_GENERIC_INITIALIZER( handlers, init, destroy ) \
795 IMFS_NODE_CONTROL_INITIALIZER( handlers, init, destroy )
796
804#define IMFS_GENERIC_CONTROL_INITIALIZER( handlers, init, destroy ) \
805 IMFS_NODE_CONTROL_INITIALIZER( handlers, init, destroy )
806
817#define IMFS_GENERIC_NODE_INITIALIZER( node_control, name, namelen, mode ) \
818 { IMFS_NODE_INITIALIZER( node_control, name, namelen, mode ), NULL }
819
833static inline void IMFS_generic_node_preinitialize(
834 IMFS_generic_t *node,
835 const IMFS_node_control *node_control,
836 const char *name,
837 size_t namelen,
838 mode_t mode
839)
840{
841 IMFS_node_preinitialize( &node->Node, node_control, name, namelen, mode );
842}
843
904extern int IMFS_make_generic_node(
905 const char *path,
906 mode_t mode,
907 const IMFS_node_control *node_control,
908 void *context
909);
910
921extern int IMFS_mount(
922 rtems_filesystem_mount_table_entry_t *mt_entry, /* IN */
923 const void *data
924);
925
929extern int IMFS_unmount(
930 rtems_filesystem_mount_table_entry_t *mt_entry /* IN */
931);
932
944extern ssize_t IMFS_memfile_write(
945 IMFS_memfile_t *memfile,
946 off_t start,
947 const unsigned char *source,
948 unsigned int length
949);
950
961extern int device_open(
962 rtems_libio_t *iop, /* IN */
963 const char *pathname, /* IN */
964 int oflag, /* IN */
965 mode_t mode /* IN */
966);
967
968extern int device_close(
969 rtems_libio_t *iop /* IN */
970);
971
972extern ssize_t device_read(
973 rtems_libio_t *iop, /* IN */
974 void *buffer, /* IN */
975 size_t count /* IN */
976);
977
978extern ssize_t device_write(
979 rtems_libio_t *iop, /* IN */
980 const void *buffer, /* IN */
981 size_t count /* IN */
982);
983
984extern int device_ioctl(
985 rtems_libio_t *iop,
986 ioctl_command_t command,
987 void *buffer
988);
989
990extern int device_ftruncate(
991 rtems_libio_t *iop, /* IN */
992 off_t length /* IN */
993);
994
1004extern int IMFS_utimens(
1006 struct timespec times[2]
1007);
1008
1012extern int IMFS_fchmod(
1014 mode_t mode
1015);
1016
1024extern int IMFS_symlink(
1025 const rtems_filesystem_location_info_t *parentloc,
1026 const char *name,
1027 size_t namelen,
1028 const char *target
1029);
1030
1047extern int IMFS_statvfs(
1049 struct statvfs *buf
1050);
1051
1059extern ssize_t IMFS_readlink(
1061 char *buf,
1062 size_t bufsize
1063);
1064
1071extern int IMFS_rename(
1072 const rtems_filesystem_location_info_t *oldparentloc,
1074 const rtems_filesystem_location_info_t *newparentloc,
1075 const char *name,
1076 size_t namelen
1077);
1084extern int IMFS_rmnod(
1085 const rtems_filesystem_location_info_t *parentloc,
1087);
1088
1089/*
1090 * Turn on IMFS assertions when RTEMS_DEBUG is defined.
1091 */
1092#ifdef RTEMS_DEBUG
1093 #include <assert.h>
1094
1095 #define IMFS_assert(_x) assert(_x)
1096#else
1097 #define IMFS_assert(_x)
1098#endif
1099
1100static inline void IMFS_Set_handlers( rtems_filesystem_location_info_t *loc )
1101{
1102 IMFS_jnode_t *node = (IMFS_jnode_t *) loc->node_access;
1103
1104 loc->handlers = node->control->handlers;
1105}
1106
1107static inline void IMFS_add_to_directory(
1108 IMFS_jnode_t *dir_node,
1109 IMFS_jnode_t *entry_node
1110)
1111{
1112 IMFS_directory_t *dir = (IMFS_directory_t *) dir_node;
1113
1114 entry_node->Parent = dir_node;
1115 rtems_chain_append_unprotected( &dir->Entries, &entry_node->Node );
1116}
1117
1118static inline void IMFS_remove_from_directory( IMFS_jnode_t *node )
1119{
1120 IMFS_assert( node->Parent != NULL );
1121 node->Parent = NULL;
1122 rtems_chain_extract_unprotected( &node->Node );
1123}
1124
1125static inline bool IMFS_is_directory( const IMFS_jnode_t *node )
1126{
1127 return S_ISDIR( node->st_mode );
1128}
1129
1130#define IMFS_STAT_FMT_HARD_LINK 0
1131
1132static inline bool IMFS_is_hard_link( mode_t mode )
1133{
1134 return ( mode & S_IFMT ) == IMFS_STAT_FMT_HARD_LINK;
1135}
1136
1137static inline ino_t IMFS_node_to_ino( const IMFS_jnode_t *node )
1138{
1139 return (ino_t) ((uintptr_t) node);
1140}
1141
1149static inline void *IMFS_generic_get_context_by_node(
1150 const IMFS_jnode_t *node
1151)
1152{
1153 const IMFS_generic_t *generic = (const IMFS_generic_t *) node;
1154
1155 return generic->context;
1156}
1157
1158static inline void *IMFS_generic_get_context_by_location(
1160)
1161{
1162 return loc->node_access_2;
1163}
1164
1165static inline void *IMFS_generic_get_context_by_iop(
1166 const rtems_libio_t *iop
1167)
1168{
1169 return IMFS_generic_get_context_by_location( &iop->pathinfo );
1170}
1171
1172static inline dev_t IMFS_generic_get_device_identifier_by_node(
1173 const IMFS_jnode_t *node
1174)
1175{
1176 return rtems_filesystem_make_dev_t_from_pointer( node );
1177}
1178
1179#ifdef __cplusplus
1180}
1181#endif
1183#endif
1184/* end of include file */
clock_t times(struct tms *ptms)
Definition: __times.c:97
This header file provides the interfaces of the Assert Handler.
void IMFS_do_nothing_destroy(IMFS_jnode_t *node)
Does nothing.
Definition: imfs_node.c:125
IMFS_jnode_t * IMFS_node_initialize_default(IMFS_jnode_t *node, void *arg)
Returns the node and does nothing else.
Definition: imfs_initsupp.c:100
IMFS_jnode_t * IMFS_node_remove_default(IMFS_jnode_t *node)
Returns the node and does nothing else.
Definition: imfs_node.c:118
void(* IMFS_node_control_destroy)(IMFS_jnode_t *node)
Destroys an IMFS node.
Definition: imfs.h:218
IMFS_jnode_t *(* IMFS_node_control_remove)(IMFS_jnode_t *node)
Prepares the removal of an IMFS node from its parent directory.
Definition: imfs.h:192
IMFS_jnode_t * IMFS_node_initialize_generic(IMFS_jnode_t *node, void *arg)
Returns the node and sets the generic node context.
Definition: imfs_make_generic_node.c:44
IMFS_jnode_t *(* IMFS_node_control_initialize)(IMFS_jnode_t *node, void *arg)
Initializes an IMFS node.
Definition: imfs.h:140
int IMFS_make_generic_node(const char *path, mode_t mode, const IMFS_node_control *node_control, void *context)
Makes a generic IMFS node.
Definition: imfs_make_generic_node.c:56
void IMFS_node_destroy_default(IMFS_jnode_t *node)
Frees the node.
Definition: imfs_node_destroy_default.c:44
int IMFS_statvfs(const rtems_filesystem_location_info_t *loc, struct statvfs *buf)
Sets buf with the IMFS statistics.
Definition: imfs_statvfs.c:41
int IMFS_chown(const rtems_filesystem_location_info_t *loc, uid_t owner, gid_t group)
Change the owner of IMFS.
Definition: imfs_chown.c:47
int IMFS_rmnod(const rtems_filesystem_location_info_t *parentloc, const rtems_filesystem_location_info_t *loc)
IMFS node removal handler.
Definition: imfs_rmnod.c:46
int IMFS_link(const rtems_filesystem_location_info_t *parentloc, const rtems_filesystem_location_info_t *targetloc, const char *name, size_t namelen)
Create a new IMFS link node.
Definition: imfs_link.c:45
void IMFS_default_deallocate_block(void *)
The default imfs block deallocator.
Definition: imfs_memfile.c:860
int IMFS_rename(const rtems_filesystem_location_info_t *oldparentloc, const rtems_filesystem_location_info_t *oldloc, const rtems_filesystem_location_info_t *newparentloc, const char *name, size_t namelen)
Rename the IMFS.
Definition: imfs_rename.c:69
void *(* IMFS_memfile_allocator)(void)
The type of allocator function pointer.
Definition: imfs.h:292
void IMFS_fsunmount(rtems_filesystem_mount_table_entry_t *mt_entry)
Unmount this instance of IMFS.
Definition: imfs_fsunmount.c:55
int IMFS_mount(rtems_filesystem_mount_table_entry_t *mt_entry, const void *data)
Mount an IMFS.
Definition: imfs_mount.c:46
int IMFS_make_linearfile(const char *path, mode_t mode, const void *data, size_t size)
Makes a linear IMFS file.
Definition: imfs_make_linfile.c:34
void * IMFS_default_allocate_block(void)
The default imfs block allocator.
Definition: imfs_memfile.c:855
int rtems_tarfs_load(const char *mountpoint, const void *tar_image, size_t tar_size)
RTEMS load tarfs.
Definition: imfs_load_tar.c:46
void IMFS_node_free(const rtems_filesystem_location_info_t *loc)
Free an IMFS node.
Definition: imfs_node.c:107
int IMFS_unmount(rtems_filesystem_mount_table_entry_t *mt_entry)
Unmount an IMFS.
Definition: imfs_unmount.c:46
void IMFS_node_destroy(IMFS_jnode_t *node)
Destroy an IMFS node.
Definition: imfs_node.c:100
int IMFS_symlink(const rtems_filesystem_location_info_t *parentloc, const char *name, size_t namelen, const char *target)
Create a new IMFS symbolic link node.
Definition: imfs_symlink.c:47
int IMFS_add_node(const char *path, IMFS_jnode_t *node, void *arg)
Adds an IMFS node.
Definition: imfs_add_node.c:42
int IMFS_node_clone(rtems_filesystem_location_info_t *loc)
Clone an IMFS node.
Definition: imfs_node.c:91
size_t IMFS_default_free_space(void)
The default free space calculator.
Definition: imfs_memfile.c:865
int IMFS_utimens(const rtems_filesystem_location_info_t *loc, struct timespec times[2])
Set IMFS file access and modification times.
Definition: imfs_utimens.c:44
int IMFS_mknod(const rtems_filesystem_location_info_t *parentloc, const char *name, size_t namelen, mode_t mode, dev_t dev)
Create an IMFS node.
Definition: imfs_mknod.c:63
void IMFS_eval_path(rtems_filesystem_eval_path_context_t *ctx)
IMFS evaluation node support.
Definition: imfs_eval.c:199
IMFS_jnode_t * IMFS_create_node(const rtems_filesystem_location_info_t *parentloc, const IMFS_node_control *node_control, size_t node_size, const char *name, size_t namelen, mode_t mode, void *arg)
Create an IMFS node.
Definition: imfs_creat.c:45
void(* IMFS_memfile_deallocator)(void *memory)
The type of deallocator function pointer.
Definition: imfs.h:297
int IMFS_stat(const rtems_filesystem_location_info_t *loc, struct stat *buf)
Perform a status processing for the IMFS.
Definition: imfs_stat.c:46
size_t(* IMFS_memfile_free_space)(void)
The get_free_space function pointer.
Definition: imfs.h:304
ssize_t IMFS_readlink(const rtems_filesystem_location_info_t *loc, char *buf, size_t bufsize)
Put IMFS symbolic link into buffer.
Definition: imfs_symlink.c:76
int IMFS_fchmod(const rtems_filesystem_location_info_t *loc, mode_t mode)
Change the IMFS file mode.
Definition: imfs_fchmod.c:43
void IMFS_eval_path_devfs(rtems_filesystem_eval_path_context_t *ctx)
IMFS device filesystem evaluation node support.
Definition: imfs_eval_devfs.c:123
uint32_t rtems_device_major_number
This integer type represents the major number of devices.
Definition: io.h:103
uint32_t rtems_device_minor_number
This integer type represents the minor number of devices.
Definition: io.h:115
LibIO Internal Interface.
POSIX FIFO/pipe File System Support.
This header file provides the statvfs() and fstatvfs() interfaces.
This structure represents a chain node.
Definition: chain.h:78
Definition: imfs.h:354
Definition: imfs.h:348
Definition: imfs.h:395
Definition: imfs.h:370
Definition: imfs.h:444
Definition: imfs.h:400
Definition: imfs.h:271
Definition: imfs.h:405
Definition: imfs.h:382
The ops table for user defined allocator-deallocator for IMFS memfile data blocks.
Definition: imfs.h:314
Definition: imfs.h:375
Definition: imfs.h:248
Definition: imfs.h:437
Definition: imfs.h:450
IMFS node control.
Definition: imfs.h:241
File system node operations table.
Definition: libio.h:1008
File system operations table.
Definition: libio.h:475
Definition: intercom.c:87
Definition: pipe.h:57
Path evaluation context.
Definition: libio.h:105
Contain file system specific information which is required to support fpathconf().
Definition: libio.h:1294
File system location.
Definition: fs.h:72
Mount table entry.
Definition: libio.h:1661
An open file data structure.
Definition: libio.h:1325
Definition: statvfs.h:56
This union represents a chain control block.
Definition: chain.h:96
Definition: imfs.h:388