Skip to content

Punch Offline Ioctl, tests, scoutfs subcmd.#237

Open
aversecat wants to merge 4 commits intomainfrom
auke/hole_punch_ioctl_test
Open

Punch Offline Ioctl, tests, scoutfs subcmd.#237
aversecat wants to merge 4 commits intomainfrom
auke/hole_punch_ioctl_test

Conversation

@aversecat
Copy link
Contributor

No description provided.

@aversecat aversecat force-pushed the auke/hole_punch_ioctl_test branch from 19fdbf1 to 613cfce Compare July 3, 2025 15:49
@aversecat aversecat force-pushed the auke/hole_punch_ioctl_test branch 2 times, most recently from 787cce0 to 0397962 Compare October 31, 2025 16:30
@aversecat aversecat force-pushed the auke/hole_punch_ioctl_test branch from 0397962 to d624b8b Compare November 14, 2025 01:40
@aversecat aversecat force-pushed the auke/hole_punch_ioctl_test branch from d624b8b to 3879728 Compare December 2, 2025 17:13
@aversecat aversecat force-pushed the auke/hole_punch_ioctl_test branch from 3879728 to ab3dd3f Compare February 2, 2026 18:22
@aversecat
Copy link
Contributor Author

retest

1 similar comment
@aversecat
Copy link
Contributor Author

retest

zabbo and others added 4 commits March 4, 2026 13:46
Add an archive layer ioctl for converting offline extents into sparse
extents without relying on or modifying data_version.  This is helpful
when working with files with very large sparse regions.

Signed-off-by: Zach Brown <zab@versity.com>
The current code here only works if the passed in start block is exactly
the start of an offline extent. On top of that, it only will punch a
single extent, ever, due to the test used after finding an extent.

The reason is that we break the loop if the start isn't exactly the
first block of the extent, even if the last block of the extent is
within the wanted hole.

With this change, it doesn't matter if the start is either part of an
offline extent, or a hole, and, we can punch holes that encompass multiple
extents separated by holes, punching all of them away.

Signed-off-by: Auke Kok <auke.kok@versity.com>
A minimal punch_offline ioctl wrapper. Argument style is adopted from
stage/release.

Following the syntax for the option of stage/release, this calls the
punch offline ioctl, punching any offline extent within the designated
range from offset with length.

Signed-off-by: Auke Kok <auke.kok@versity.com>
Basic testing for the punch-offline ioctl code. The tests consist of a
bunch of negative testing to make sure things that are expressly not
allowed fail, followed by a bunch of known-expected outcome tests that
punches holes in several patterns, verifying them.

Signed-off-by: Auke Kok <auke.kok@versity.com>
@aversecat aversecat force-pushed the auke/hole_punch_ioctl_test branch from ab3dd3f to 250539a Compare March 4, 2026 18:47
@aversecat
Copy link
Contributor Author

rebased

@aversecat
Copy link
Contributor Author

retest

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.

2 participants