Skip to content

fallocate: adds implementation#512

Open
xfbs wants to merge 2 commits intouutils:mainfrom
xfbs:fallocate
Open

fallocate: adds implementation#512
xfbs wants to merge 2 commits intouutils:mainfrom
xfbs:fallocate

Conversation

@xfbs
Copy link
Copy Markdown

@xfbs xfbs commented Mar 28, 2026

implements allocate, collapse-range, dig-holes, insert-range, punch-holes, zero-range and posix_fallocate.

this is my first contribution, please be kind :D

I've written some simple tests for it. What I have not tested is to see if the punch holes actually worked (I think i need to use fiemap for that, to get the raw extents.. can do that in the future, thought it wasn't worth it for now).

xfbs added 2 commits March 28, 2026 02:20
implements allocate, collapse-range, dig-holes, insert-range,
punch-holes, zero-range and posix_fallocate.
- Replace manual `bytes % threshold == 0` with `bytes.is_multiple_of(threshold)`
- Gate Linux-only imports and helpers with `#[cfg(target_os = "linux")]`
- Gate Linux-only tests with `#[cfg(target_os = "linux")]`
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant