|
| #define | IMFS_MEMFILE_DEFAULT_BYTES_PER_BLOCK 128 |
|
#define | IMFS_MEMFILE_BYTES_PER_BLOCK imfs_memfile_bytes_per_block |
|
#define | IMFS_MEMFILE_BLOCK_SLOTS (IMFS_MEMFILE_BYTES_PER_BLOCK / sizeof(void *)) |
|
#define | FIRST_INDIRECT (0) |
|
#define | LAST_INDIRECT (IMFS_MEMFILE_BLOCK_SLOTS - 1) |
|
#define | FIRST_DOUBLY_INDIRECT (LAST_INDIRECT + 1) |
| #define | LAST_DOUBLY_INDIRECT |
|
#define | FIRST_TRIPLY_INDIRECT (LAST_DOUBLY_INDIRECT + 1) |
| #define | LAST_TRIPLY_INDIRECT |
|
#define | IMFS_MEMFILE_MAXIMUM_SIZE (LAST_TRIPLY_INDIRECT * IMFS_MEMFILE_BYTES_PER_BLOCK) |
|
#define | IMFS_NAME_MAX _POSIX_NAME_MAX |
| #define | IMFS_NODE_CONTROL_INITIALIZER(handlers, init, destroy) |
| | Initializer for an IMFS node control.
|
| #define | IMFS_NODE_INITIALIZER(node_control, name, namelen, mode) |
| | Initializer for an IMFS node.
|
|
#define | IMFS_assert(_x) |
|
#define | IMFS_STAT_FMT_HARD_LINK 0 |
|
|
int | IMFS_initialize (rtems_filesystem_mount_table_entry_t *mt_entry, const void *data) |
|
int | IMFS_initialize_support (rtems_filesystem_mount_table_entry_t *mt_entry, const void *data) |
|
void | IMFS_fsunmount (rtems_filesystem_mount_table_entry_t *mt_entry) |
| | Unmount this instance of IMFS.
|
| int | rtems_tarfs_load (const char *mountpoint, const void *tar_image, size_t tar_size) |
| | RTEMS load tarfs.
|
|
void | IMFS_node_destroy (IMFS_jnode_t *node) |
| | Destroy an IMFS node.
|
|
int | IMFS_node_clone (rtems_filesystem_location_info_t *loc) |
| | Clone an IMFS node.
|
|
void | IMFS_node_free (const rtems_filesystem_location_info_t *loc) |
| | Free an IMFS node.
|
| int | IMFS_stat (const rtems_filesystem_location_info_t *loc, struct stat *buf) |
| | Perform a status processing for the IMFS.
|
|
int | IMFS_stat_file (const rtems_filesystem_location_info_t *loc, struct stat *buf) |
|
void | IMFS_eval_path (rtems_filesystem_eval_path_context_t *ctx) |
| | IMFS evaluation node support.
|
|
void | IMFS_eval_path_devfs (rtems_filesystem_eval_path_context_t *ctx) |
| | IMFS device filesystem evaluation node support.
|
| 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.
|
| int | IMFS_chown (const rtems_filesystem_location_info_t *loc, uid_t owner, gid_t group) |
| | Change the owner of IMFS.
|
| 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.
|
|
IMFS_jnode_t * | IMFS_initialize_node (IMFS_jnode_t *node, const IMFS_node_control *node_control, const char *name, size_t namelen, mode_t mode, void *arg) |
| 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.
|
| int | IMFS_add_node (const char *path, IMFS_jnode_t *node, void *arg) |
| | Adds an IMFS node.
|
|
int | IMFS_make_node (const char *path, mode_t mode, const IMFS_node_control *node_control, size_t node_size, void *context) |
| int | IMFS_make_linearfile (const char *path, mode_t mode, const void *data, size_t size) |
| | Makes a linear IMFS file.
|
|
int | IMFS_mount (rtems_filesystem_mount_table_entry_t *mt_entry) |
| | Mount an IMFS.
|
|
int | IMFS_unmount (rtems_filesystem_mount_table_entry_t *mt_entry) |
| | Unmount an IMFS.
|
| int | IMFS_utimens (const rtems_filesystem_location_info_t *loc, struct timespec times[2]) |
| | Set IMFS file access and modification times.
|
|
int | IMFS_fchmod (const rtems_filesystem_location_info_t *loc, mode_t mode) |
| | Change the IMFS file mode.
|
| 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.
|
| ssize_t | IMFS_readlink (const rtems_filesystem_location_info_t *loc, char *buf, size_t bufsize) |
| | Put IMFS symbolic link into buffer.
|
| 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.
|
| int | IMFS_rmnod (const rtems_filesystem_location_info_t *parentloc, const rtems_filesystem_location_info_t *loc) |
| | IMFS node removal handler.
|
|
This section contains the set of handlers used to map operations on IMFS device nodes onto calls to the RTEMS Classic API IO Manager.
|
|
int | device_open (rtems_libio_t *iop, const char *pathname, int oflag, mode_t mode) |
|
int | device_close (rtems_libio_t *iop) |
|
ssize_t | device_read (rtems_libio_t *iop, void *buffer, size_t count) |
|
ssize_t | device_write (rtems_libio_t *iop, const void *buffer, size_t count) |
|
int | device_ioctl (rtems_libio_t *iop, ioctl_command_t command, void *buffer) |
|
int | device_ftruncate (rtems_libio_t *iop, off_t length) |
In-Memory File System Support.
| #define IMFS_MEMFILE_DEFAULT_BYTES_PER_BLOCK 128 |
IMFS "memfile" information
The data structure for the in-memory "memfiles" is based on classic UNIX.
block_ptr is a pointer to a block of IMFS_MEMFILE_BYTES_PER_BLOCK in length which could be data or a table of pointers to blocks.
Setting IMFS_MEMFILE_BYTES_PER_BLOCK to different values has a significant impact on the maximum file size supported as well as the amount of memory wasted due to internal file fragmentation. The following is a list of maximum file sizes based on various settings
max_filesize with blocks of 16 is 1,328
max_filesize with blocks of 32 is 18,656
max_filesize with blocks of 64 is 279,488
max_filesize with blocks of 128 is 4,329,344
max_filesize with blocks of 256 is 68,173,568
max_filesize with blocks of 512 is 1,082,195,456