The VFS library can be used in single-threaded or multi-threaded environments and depending on that, signals are handled by the same thread which uses the VFS library or possibly by a different thread. If a VFS plugin needs to block to wait for a signal, there is currently no way which works reliably in both environments. For this reason, this commit makes the interface of the VFS library nonblocking, similar to the File_system session interface. The most important changes are: - Directories are created and opened with the 'opendir()' function and the directory entries are read with the recently introduced 'queue_read()' and 'complete_read()' functions. - Symbolic links are created and opened with the 'openlink()' function and the link target is read with the 'queue_read()' and 'complete_read()' functions and written with the 'write()' function. - The 'write()' function does not wait for signals anymore. This can have the effect that data written by a VFS library user has not been processed by a file system server yet when the library user asks for the size of the file or closes it (both done with RPC functions at the file system server). For this reason, a user of the VFS library should request synchronization before calling 'stat()' or 'close()'. To make sure that a file system server has processed all write request packets which a client submitted before the synchronization request, synchronization is now requested at the file system server with a synchronization packet instead of an RPC function. Because of this change, the synchronization interface of the VFS library is now split into 'queue_sync()' and 'complete_sync()' functions. Fixes #2399 |
||
---|---|---|
.. | ||
exfat | ||
ext2 | ||
ntfs-3g | ||
directory.h | ||
file.h | ||
fuse_fs_main.cc | ||
mode_util.h | ||
node.h | ||
README | ||
symlink.h | ||
util.h |
The fuse_fs server provides access to a FUSE based file system by using a File_system_session. The File_system_session component implementation is independent from each FUSE based file system. fuse_fs only calls the FUSE operation in question directly. These operations are provided by the FUSE file system and Genode's libfuse library makes sure, that each operation is executeable, e.g. by using a dummy function in case it is not provided by the FUSE file system. Therefore, to utilize a FUSE file system, the FUSE file system is linked against libfuse as well as the File_system_session component. For each fuse_fs server there is a binary (.e.g. 'os/src/server/fuse_fs/ext2'). Note: write-support is supported but considered to be experimantal at this point and for now using it is NOT recommended. To use the ext2_fuse_fs server in noux the following config snippet may be used: ! <start name="ext2_fuse_fs"> ! <resource name="RAM" quantum="8M"/> ! <provides> <service name="File_system"/> </provides> ! <config> ! <policy label_prefix="noux -> fuse" root="/" writeable="no" /> ! </config> ! </start>