Module fs

Module fs 

Source

StructsΒ§

IoVec
Linux iovec structure for vectored I/O operations This structure matches the Linux kernel’s definition for struct iovec
LinuxDirent64
Linux struct linux_dirent64 (for getdents64 syscall)
LinuxStat
Linux stat structure for RISC-V 64-bit Matches asm-generic struct stat layout used by musl on 64-bit.
LinuxStatx
Linux statx structure (matches Linux UAPI layout)
LinuxStatxTimestamp
Linux statx timestamp structure

EnumsΒ§

OpenMode πŸ”’

ConstantsΒ§

FD_CLOEXEC
F_DUPFD
F_DUPFD_CLOEXEC
F_GETFD
F_GETFL
F_GETLEASE
F_GETLK
F_GETOWN
F_GETSIG
F_NOTIFY
F_SETFD
F_SETFL
F_SETLEASE
F_SETLK
F_SETLKW
F_SETOWN
F_SETSIG
GRND_INSECURE
GRND_NONBLOCK
GRND_RANDOM
LOG_FCNTL πŸ”’
Linux sys_fcntl implementation for Scarlet VFS v2 Currently provides basic logging of commands to understand usage patterns
MAX_ARG_COUNT πŸ”’
MAX_PATH_LENGTH πŸ”’
O_APPEND
O_ASYNC
O_CLOEXEC
O_CREAT
O_DIRECT
O_DIRECTORY
O_DSYNC
O_EXCL
O_LARGEFILE
O_NOATIME
O_NOCTTY
O_NOFOLLOW
O_NONBLOCK
O_PATH
O_RDONLY
O_RDWR
O_SYNC
O_TMPFILE
O_TRUNC
O_WRONLY
RENAME_EXCHANGE πŸ”’
RENAME_NOREPLACE πŸ”’
RENAME_WHITEOUT πŸ”’
STATX_ATIME
STATX_BASIC_STATS
STATX_BLOCKS
STATX_BTIME
STATX_CTIME
STATX_GID
STATX_INO
STATX_MODE
STATX_MTIME
STATX_NLINK
STATX_SIZE
STATX_TYPE
STATX_UID
S_IFBLK
S_IFCHR
S_IFDIR
S_IFIFO
S_IFLNK
S_IFMT
S_IFREG
S_IFSOCK
S_IRGRP
S_IROTH
S_IRUSR
S_IRWXG
S_IRWXO
S_IRWXU
S_IWGRP
S_IWOTH
S_IWUSR
S_IXGRP
S_IXOTH
S_IXUSR

StaticsΒ§

XORSHIFT_STATE πŸ”’

FunctionsΒ§

fill_pseudo_random πŸ”’
fill_statx_from_stat πŸ”’
get_path_str_v2 πŸ”’
Helper function to replace the missing get_path_str function TODO: This should be moved to a shared helper when VFS v2 provides public API
is_wl_shm_path πŸ”’
next_pseudo_random_u64 πŸ”’
remap_shm_path πŸ”’
statx_timestamp_from_secs πŸ”’
stream_error_to_errno πŸ”’
sys_chdir
Linux sys_chdir system call implementation (syscall 49) Change current working directory
sys_close
sys_dup
sys_dup3
sys_epoll_create1
Linux epoll_create1 implementation (stub)
sys_epoll_ctl
Linux epoll_ctl implementation (stub)
sys_epoll_pwait
Linux epoll_pwait implementation (stub)
sys_epoll_wait
Linux epoll_wait implementation (stub)
sys_eventfd2
eventfd2 - create file descriptor for event notification
sys_exec
Linux sys_exec system call implementation Executes a program specified by the given path, replacing the current process image with a new one. Also allows passing arguments and environment variables to the new program.
sys_execve
Linux execve system call implementation
sys_faccessat
Linux sys_faccessat implementation (dummy: always returns 0)
sys_faccessat2
Linux faccessat2 system call (syscall 439)
sys_fallocate
Linux sys_fallocate - Manipulate file space
sys_fchmod
Linux sys_fchmod implementation (stub)
sys_fcntl
sys_flock
Linux sys_flock - Apply or remove an advisory lock on an open file
sys_fsync
Linux sys_fsync system call implementation (stub) Synchronize a file’s in-core state with storage device
sys_ftruncate
Linux sys_ftruncate implementation
sys_getcwd
Linux sys_getcwd system call implementation Get current working directory
sys_getdents64
getdents64 syscall implementation
sys_getrandom
Linux sys_getrandom implementation
sys_ioctl
Linux ioctl system call implementation
sys_link
sys_linkat
Linux sys_linkat implementation for Scarlet VFS v2
sys_lseek
sys_mkdir
sys_mkdirat
Linux sys_mkdirat implementation
sys_newfstat
Linux sys_newfstat implementation for Scarlet VFS v2
sys_newfstatat
Linux sys_newfstatat implementation for Scarlet VFS v2
sys_openat
Linux sys_openat implementation for Scarlet VFS v2
sys_ppoll
Minimal Linux ppoll implementation
sys_pread64
sys_pselect6
Minimal Linux pselect6 implementation (stub)
sys_pwrite64
sys_read
sys_readlinkat
Linux sys_readlinkat implementation
sys_readv
Linux readv system call implementation
sys_renameat2
Linux sys_renameat2 system call implementation (syscall 276) Rename/move a file or directory with additional flags
sys_statx
Linux sys_statx implementation for Scarlet VFS v2
sys_umask
Linux sys_umask implementation (stub)
sys_unlink
sys_unlinkat
Linux sys_unlinkat implementation for Scarlet VFS v2
sys_write
sys_writev
Linux writev system call implementation
to_absolute_path_v2 πŸ”’
VFS v2 helper function for path absolutization using VfsManager