summaryrefslogtreecommitdiffstats
path: root/cpukit/libfs/src/imfs/imfs_initsupp.c (follow)
Commit message (Collapse)AuthorAgeFilesLines
* cpukit/libfs/src/imfs: Change license to BSD-2Joel Sherrill2022-03-221-3/+22
| | | | Updates #3053.
* doxygen: Switch @brief and @ingroupSebastian Huber2020-04-281-1/+2
| | | | This order change fixes the Latex documentation build via Doxygen.
* Canonicalize config.h includeSebastian Huber2020-04-161-2/+2
| | | | | | | | Use the following variant which was already used by most source files: #ifdef HAVE_CONFIG_H #include "config.h" #endif
* imfs: Simplify code generationSebastian Huber2020-03-091-11/+17
| | | | Update #3894.
* imfs: Remove unused handlersSebastian Huber2020-03-091-6/+1
| | | | Update #3894.
* imfs: Constify imfs_memfile_bytes_per_blockSebastian Huber2020-03-091-35/+0
| | | | | | | | The CONFIGURE_IMFS_MEMFILE_BYTES_PER_BLOCK value is validated by <rtems/confdefs/libio.h>. Changing this value during runtime could lead to memory corruption. Update #3894.
* IMFS: Include <rtems/imfs.h>Sebastian Huber2017-12-131-1/+1
| | | | | | Prepare for header file move to common include directory. Update #3254.
* imfs: Untangle dependenciesSebastian Huber2016-09-191-89/+0
| | | | | This helps to use IMFS_make_generic_node() without pulling in the complete IMFS implementation.
* imfs: Fix IMFS_stat_file()Sebastian Huber2016-09-161-5/+0
| | | | | Use the adjusted and not the requested memfile bytes per block. Untangle dependencies.
* IMFS: Silence warningSebastian Huber2015-02-181-1/+1
|
* IMFS: Implement variable length node namesSebastian Huber2015-02-151-2/+6
| | | | This reduces the average node size and adds more flexibility.
* IMFS: Allow static initialization of FS infoSebastian Huber2015-02-121-42/+29
|
* IMFS: Add root directory to FS infoSebastian Huber2015-02-121-13/+56
| | | | Fix memory leak in IMFS_fsunmount().
* IMFS: Introduce IMFS_mknod_controlSebastian Huber2015-02-121-12/+14
| | | | | | Drop IMFS_node_control::node_size field and add node_size parameter to IMFS_allocate_node() and IMFS_create_node(). This reduces the size of generic nodes.
* IMFS: Use rtems_filesystem_make_dev_t_from_pointerSebastian Huber2015-02-041-3/+0
|
* IMFS: Replace node union with individual structSebastian Huber2015-01-271-8/+6
| | | | | | This reduces the average node size. Add and use IMFS_GENERIC_INITIALIZER().
* Change all references of rtems.com to rtems.org.Chris Johns2014-03-211-1/+1
|
* PR2160: imfs: Use ENOSYS for unsupported nodesSebastian Huber2013-12-111-2/+13
| | | | | Return an error status with errno set to ENOSYS during node creation for nodes not available in the current configuration.
* IMFS: Resource leakGedare Bloom2013-09-051-0/+1
| | | | Free fs_info in case root_node is NULL.
* Include missing <string.h>Sebastian Huber2013-07-231-0/+1
|
* IMFS: Fix reference count for debug enabledSebastian Huber2013-06-211-3/+3
|
* libfs: Doxygen Enhancement Task #2Alex Ivanov2012-12-181-2/+7
| | | | http://www.google-melange.com/gci/task/view/google/gci2012/8032207
* Filesystem: Reject removal of root nodesSebastian Huber2012-10-071-2/+1
| | | | | | | Reject the removal of file system instance root nodes in rmdir() and unlink() and return the EBUSY error status. File system instances can be removed with unmount(). Remove root node special cases in IMFS, DOSFS, and RFS.
* Filesystem: Change pathconf_limits_and_optionsSebastian Huber2012-05-151-1/+1
| | | | | | The pathconf_limits_and_options field of rtems_filesystem_mount_table_entry_t is now a const pointer to reduce the read-write memory demands of file system instances.
* Filesystem: Move operations to mount table entrySebastian Huber2012-05-151-1/+1
| | | | | | | | | | | The scope of the file system operations is the file system instance. The scope of the file system node handlers is the file location. The benefit of moving the operations to the mount table entry is a size reduction of the file location (rtems_filesystem_location_info_t). The code size is slightly increased due to additional load instructions. Restructure rtems_filesystem_mount_table_entry_t to improve cache efficiency.
* Remove All CVS Id Strings Possible Using a ScriptJoel Sherrill2012-05-111-2/+0
| | | | | | | | | | | | Script does what is expected and tries to do it as smartly as possible. + remove occurrences of two blank comment lines next to each other after Id string line removed. + remove entire comment blocks which only exited to contain CVS Ids + If the processing left a blank line at the top of a file, it was removed.
* IMFS: Add and use node controlSebastian Huber2012-03-131-59/+77
| | | | | | Add and use structure IMFS_node_control with support functions. This helps to make high level functions independent of the node type and reduces the number of branches in the code.
* IMFS: Reference counting for nodesSebastian Huber2012-03-131-0/+38
| | | | | The introduction of reference counting of nodes avoids the removal of open nodes and potential usage of freed memory.
* Filesystem: Reference counting for locationsSebastian Huber2012-03-131-20/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | o A new data structure rtems_filesystem_global_location_t was introduced to be used for o the mount point location in the mount table entry, o the file system root location in the mount table entry, o the root directory location in the user environment, and o the current directory location in the user environment. During the path evaluation global start locations are obtained to ensure that the current file system instance will be not unmounted in the meantime. o The user environment uses now reference counting and is protected from concurrent access. o The path evaluation process was completely rewritten and simplified. The IMFS, RFS, NFS, and DOSFS use now a generic path evaluation method. Recursive calls in the path evaluation have been replaced with iteration to avoid stack overflows. Only the evaluation of symbolic links is recursive. No dynamic memory allocations and intermediate buffers are used in the high level path evaluation. No global locks are held during the file system instance specific path evaluation process. o Recursive symbolic link evaluation is now limited by RTEMS_FILESYSTEM_SYMLOOP_MAX. Applications can retrieve this value via sysconf(). o The device file system (devFS) uses now no global variables and allocation from the workspace. Node names are allocated from the heap. o The upper layer lseek() performs now some parameter checks. o The upper layer ftruncate() performs now some parameter checks. o unmask() is now restricted to the RWX flags and protected from concurrent access. o The fchmod_h and rmnod_h file system node handlers are now a file system operation. o The unlink_h operation has been removed. All nodes are now destroyed with the rmnod_h operation. o New lock_h, unlock_h, clonenod_h, and are_nodes_equal_h file system operations. o The path evaluation and file system operations are now protected by per file system instance lock and unlock operations. o Fix and test file descriptor duplicate in fcntl(). o New test fstests/fsnofs01.
* 2010-08-09 Bharath Suri <bharath.s.jois@gmail.com>Joel Sherrill2010-08-101-0/+3
| | | | | | | | | | PR 1660/filesystem * libfs/src/pipe/fifo.c, libfs/src/pipe/pipe.h: Changed int pipe_release to void pipe_release. * libfs/src/imfs/imfs_fifo.c: Corresponding change to IMFS_fifo_close since pipe_release does not return any error. * libfs/src/imfs/imfs_initsupp.c: Changes to improve IMFS_determine_bytes_per_block
* 2010-06-24 Joel Sherrill <joel.sherrilL@OARcorp.com>Joel Sherrill2010-06-241-2/+0
| | | | | | | | | * libfs/src/imfs/imfs_creat.c, libfs/src/imfs/imfs_debug.c, libfs/src/imfs/imfs_directory.c, libfs/src/imfs/imfs_eval.c, libfs/src/imfs/imfs_fsunmount.c, libfs/src/imfs/imfs_getchild.c, libfs/src/imfs/imfs_initsupp.c, libfs/src/imfs/ioman.c, libfs/src/imfs/memfile.c: Evaluate all assert calls in IMFS. Either made them conditional on RTEMS_DEBUG or eliminated them.
* 2010-06-08 Sebastian Huber <sebastian.huber@embedded-brains.de>Sebastian Huber2010-06-081-4/+3
| | | | | | | | | | | * libfs/src/imfs/fifoimfs_init.c: New file. * libfs/Makefile.am: Reflect change above. * libfs/src/imfs/imfs.h, libfs/src/imfs/imfs_eval.c, libfs/src/imfs/imfs_init.c, libfs/src/imfs/imfs_initsupp.c, libfs/src/imfs/miniimfs_init.c, libfs/src/pipe/fifo.c, libfs/src/pipe/pipe.c, libfs/src/pipe/pipe.h: Pipe support is now link-time optional. * sapi/include/confdefs.h: Reflect changes above.
* 2010-05-15 Chris Johns <chrisj@rtems.org>Chris Johns2010-05-151-0/+2
| | | | | * libfs/src/imfs/imfs_initsupp.c, libfs/src/imfs/imfs.h, libfs/src/imfs/imfs_stat.c: PR1419. Return a device for the IMFS.
* 2010-01-19 Joel Sherrill <joel.sherrill@oarcorp.com>Joel Sherrill2010-01-191-16/+5
| | | | | | | | | * libfs/src/imfs/imfs.h, libfs/src/imfs/imfs_creat.c, libfs/src/imfs/imfs_initsupp.c, libfs/src/imfs/imfs_link.c, libfs/src/imfs/imfs_load_tar.c, libfs/src/imfs/imfs_mknod.c, libfs/src/imfs/imfs_symlink.c: Create special helper method for creating the j-node for the root directory. This lets us assume that every j-node created otherwise has a parent node.
* 2008-10-14 Wei Shen <cquark@gmail.com>Joel Sherrill2008-10-141-4/+7
| | | | | | | | | | | | * Makefile.am, preinstall.am, libcsupport/src/mknod.c, libcsupport/src/open.c, libcsupport/src/pipe.c, libfs/Makefile.am, libfs/preinstall.am, libfs/src/imfs/imfs.h, libfs/src/imfs/imfs_creat.c, libfs/src/imfs/imfs_debug.c, libfs/src/imfs/imfs_eval.c, libfs/src/imfs/imfs_initsupp.c, libfs/src/imfs/imfs_mknod.c, libfs/src/imfs/imfs_stat.c, libfs/src/imfs/memfile.c: Initial commit of POSIX pipe support. * libfs/src/imfs/imfs_fifo.c, libfs/src/pipe/fifo.c, libfs/src/pipe/pipe.c, libfs/src/pipe/pipe.h: New files.
* Use "bool" instead of "rtems_boolean|boolean".Ralf Corsepius2008-09-041-2/+2
|
* Added const qualifier to various pointers and data tables toThomas Doerfler2008-05-271-4/+4
| | | | | | reduce size of data area. IMFS: Fixed creation of symbolic links to avoid a compiler warning. DOSFS: Use LibBlock instead of read() to read the boot record.
* applied patches for PR1117/1118/1119/1120Thomas Doerfler2006-07-091-0/+38
|
* Add copy-on-write semantics to rtems_tarfs_load().Eric Norum2005-02-081-2/+0
|
* 2003-09-04 Joel Sherrill <joel@OARcorp.com>Joel Sherrill2003-09-041-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | * src/dosfs/dosfs.h, src/dosfs/fat.h, src/dosfs/fat_fat_operations.h, src/dosfs/fat_file.h, src/dosfs/msdos.h, src/dosfs/msdos_create.c, src/dosfs/msdos_dir.c, src/dosfs/msdos_eval.c, src/dosfs/msdos_file.c, src/dosfs/msdos_free.c, src/dosfs/msdos_fsunmount.c, src/dosfs/msdos_handlers_dir.c, src/dosfs/msdos_handlers_file.c, src/dosfs/msdos_init.c, src/dosfs/msdos_initsupp.c, src/dosfs/msdos_misc.c, src/dosfs/msdos_mknod.c, src/dosfs/msdos_node_type.c, src/imfs/deviceio.c, src/imfs/imfs.h, src/imfs/imfs_chown.c, src/imfs/imfs_config.c, src/imfs/imfs_creat.c, src/imfs/imfs_debug.c, src/imfs/imfs_directory.c, src/imfs/imfs_eval.c, src/imfs/imfs_fchmod.c, src/imfs/imfs_fcntl.c, src/imfs/imfs_fdatasync.c, src/imfs/imfs_free.c, src/imfs/imfs_fsunmount.c, src/imfs/imfs_getchild.c, src/imfs/imfs_gtkn.c, src/imfs/imfs_handlers_device.c, src/imfs/imfs_handlers_directory.c, src/imfs/imfs_handlers_link.c, src/imfs/imfs_handlers_memfile.c, src/imfs/imfs_init.c, src/imfs/imfs_initsupp.c, src/imfs/imfs_link.c, src/imfs/imfs_mknod.c, src/imfs/imfs_mount.c, src/imfs/imfs_ntype.c, src/imfs/imfs_readlink.c, src/imfs/imfs_rmnod.c, src/imfs/imfs_stat.c, src/imfs/imfs_symlink.c, src/imfs/imfs_unixstub.c, src/imfs/imfs_unlink.c, src/imfs/imfs_unmount.c, src/imfs/imfs_utime.c, src/imfs/ioman.c, src/imfs/linearfile.c, src/imfs/memfile.c, src/imfs/miniimfs_init.c: URL for license changed.
* 2003-07-24 jennifer averett <jennifer.averett@OARcorp.com>Jennifer Averett2003-07-241-1/+2
| | | | | | | PR 434/filesystem * src/imfs/imfs_init.c: Modified to return error code * src/imfs/miniimfs_init.c: Modified to return error code * src/imfs/imfs_initsup.c: Modified to set error upon memory failure.
* 2001-05-25 Joel Sherrill <joel@OARcorp.com>Joel Sherrill2001-05-251-1/+3
| | | | | | | * src/imfs/imfs_initsupp.c: Create the root node with the desired permissions. Nodes should be created with the right permissions because chmod() is not supported by the miniIMFS so changing after creation is not possible.
* 2001-01-22 Ralf Corsepius <corsepiu@faw.uni-ulm.de>Joel Sherrill2001-01-221-0/+4
| | | | | | | * configure.in: Add src/imfs/config.h * src/imfs/Makefile.am: Add INCLUDES += -I. to pickup config.h * src/imfs/.cvsignore: Add config.h and stamp-h * src/imfs/*.c: Add config.h support.
* 2000-12-12 Jake Janovetz <janovetz@uiuc.edu>Joel Sherrill2000-12-131-3/+5
| | | | | | | | | | | | | * src/imfs/linearfile.c, src/imfs/imfs_load_tar.c: New files. * src/imfs/Makefile.am, src/imfs/imfs.h, src/imfs/imfs_creat.c, src/imfs/imfs_debug.c, src/imfs/imfs_eval.c, src/imfs/imfs_handlers_memfile.c, src/imfs/imfs_init.c, src/imfs/imfs_initsupp.c, src/imfs/imfs_stat.c, src/imfs/miniimfs_init.c: Added "tarfs". This is not really a tar filesystem. It is a way to load a tar image into the IMFS but actually leave bulky file contents in the original tar image. It essentially adds the linear file type and associated support and a loader routine.
* 2000-11-01 Joel Sherrill <joel@OARcorp.com>Joel Sherrill2000-11-011-1/+1
| | | | | | | | | | | | | | | | | * src/imfs/Makefile.am, src/imfs/deviceio.c, src/imfs/imfs_chown.c, src/imfs/imfs_config.c, src/imfs/imfs_creat.c, src/imfs/imfs_debug.c, src/imfs/imfs_directory.c, src/imfs/imfs_eval.c, src/imfs/imfs_fchmod.c, src/imfs/imfs_free.c, src/imfs/imfs_fsunmount.c, src/imfs/imfs_gtkn.c, src/imfs/imfs_init.c, src/imfs/imfs_initsupp.c, src/imfs/imfs_link.c, src/imfs/imfs_mknod.c, src/imfs/imfs_mount.c, src/imfs/imfs_readlink.c, src/imfs/imfs_rmnod.c, src/imfs/imfs_stat.c, src/imfs/imfs_symlink.c, src/imfs/imfs_unixstub.c, src/imfs/imfs_unlink.c, src/imfs/imfs_unmount.c, src/imfs/imfs_utime.c, src/imfs/ioman.c, src/imfs/memfile.c, src/imfs/miniimfs_init.c: assoc.h, error.h, libio_.h, libio.h, and libcsupport.h moved from libc to lib/include/rtems and now must be referenced as <rtems/XXX.h>. Now we do not have to reach up and over to libc to pick them up.
* Patch from Chris Johns <cjohns@cybertec.com.au> andJoel Sherrill2000-06-261-1/+1
| | | | | Jennifer Averett <jennifer.averett@oarcorp.com> to make sure "/" is created with S_IFDIR set.
* Updated copyright notice.Joel Sherrill1999-11-171-2/+1
|
* Fixed typo where memfile_handlers set twice and directory_handlersJoel Sherrill1999-11-021-3/+3
| | | | was not set.
* Added initial cut at miniIMFS which leaves out memfile and directoryJoel Sherrill1999-10-261-87/+10
| | | | | readdir support. The next step is to add a mount table and configure either the miniIMFS or the full IMFS at the application level.
* Split null handlers table to own file and renamed.Joel Sherrill1999-10-121-1/+1
| | | | Renamed IMFS handler tables to include IMFS prefix.