Available on Linux and Unix and crate feature
pool only.Expand description
The Linux syscalls behind the file store.
Constantsยง
- OPEN_
NAMED_ ๐ATTEMPTS - Names the unlinked fallback file tries before
EEXISTfails the open.
Functionsยง
- available_
bytes ๐ - Bytes available to unprivileged writers on the volume holding
path. - c_path ๐
- Converts
pathto the NUL-terminated form libc expects. Fails withInvalidInputifpathcontains an interior NUL. - drop_
cache ๐ - Drops the clean pages of
[offset, offset + len)from the page cache. - fallocate ๐
- Allocates blocks for
[offset, offset + len). - fallocate_
mode ๐ - is_
memory_ ๐backed - Whether
pathis on tmpfs or ramfs. - off_t ๐
- Converts a file offset to
off_t. Fails withEFBIGif it does not fit, the error the kernel reports for an offset past the file size limit. - open_
anonymous ๐ - Opens a nameless read-write file in
dir, close-on-exec, withO_DIRECTifdirect. - pread ๐
- One
preadintobufatoffset. - punch_
hole ๐ - Deallocates the blocks of
[offset, offset + len), keeping the file size. - pwrite ๐
- One
pwriteofbufatoffset. - tmpfile_
fault ๐ - The injected failure of the next
O_TMPFILEopen, if any. - writeback_
and_ ๐drop - Writes back
[offset, offset + len)synchronously and drops it from the page cache.