From: Dick Marinus <dick@mrns.nl>
To: util-linux@vger.kernel.org
Cc: Dick Marinus <dick@mrns.nl>
Subject: [PATCH 0/1] copyfilerange: new command to call copy-file-range
Date: Tue, 2 Dec 2025 21:14:17 +0100 [thread overview]
Message-ID: <20251202201500.1029349-1-dick@mrns.nl> (raw)
Hello!
I finally finished my work on a command to create reflinked files. Since
my last post on this mailing list I found the copy_file_range system
call and I named this command after it.
I decided to contribute this command first, when this is done I will
post another command to find duplicate blocks in two files, which can
serve as input of this command.
This command should be usable for other use cases as well, it's also
possible to create sparse files and it can be used instead of how many
people use dd if= of= skip= count=
I tried to implement everything in a similar way as used by the other
sources in this project (and I learned a lot from it).
Nothing is set in stone although I want to keep to the Unix philosophy
and not any wild features to this command.
Please let me know what can (or must) be added or improved.
Dick Marinus (1):
copyfilerange: new command to call copy-file-range
.gitignore | 1 +
configure.ac | 3 +
meson.build | 14 ++
meson_options.txt | 2 +
misc-utils/Makemodule.am | 9 +
misc-utils/copyfilerange.1.adoc | 78 +++++++
misc-utils/copyfilerange.c | 226 +++++++++++++++++++++
misc-utils/meson.build | 5 +
tests/commands.sh | 1 +
tests/expected/copyfilerange/copyfilerange | 4 +
tests/ts/copyfilerange/copyfilerange | 40 ++++
11 files changed, 383 insertions(+)
create mode 100644 misc-utils/copyfilerange.1.adoc
create mode 100644 misc-utils/copyfilerange.c
create mode 100644 tests/expected/copyfilerange/copyfilerange
create mode 100755 tests/ts/copyfilerange/copyfilerange
--
2.51.1
next reply other threads:[~2025-12-02 20:17 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-12-02 20:14 Dick Marinus [this message]
2025-12-02 20:14 ` [PATCH 1/1] copyfilerange: new command to call copy-file-range Dick Marinus
2025-12-03 19:25 ` [PATCH 0/1] " Dick Marinus
2025-12-03 19:25 ` [PATCH 1/1] " Dick Marinus
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20251202201500.1029349-1-dick@mrns.nl \
--to=dick@mrns.nl \
--cc=util-linux@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox