Thread (62 messages) 62 messages, 2 authors, 2022-01-04

Re: [PATCH v11 07/10] btrfs-progs: receive: process fallocate commands

From: Omar Sandoval <osandov@osandov.com>
Date: 2021-10-21 17:28:24
Also in: linux-btrfs, linux-fsdevel

On Thu, Oct 21, 2021 at 05:21:00PM +0300, Nikolay Borisov wrote:

On 1.09.21 г. 20:01, Omar Sandoval wrote:
quoted
From: Boris Burkov <redacted>

Send stream v2 can emit fallocate commands, so receive must support them
as well. The implementation simply passes along the arguments to the
syscall. Note that mode is encoded as a u32 in send stream but fallocate
takes an int, so there is a unsigned->signed conversion there.

Signed-off-by: Boris Burkov <redacted>
Reviewed-by: Nikolay Borisov <redacted>

However, kernel support for this hasn't landed, the kernel counterpart
patches add definitions but don't actually implement the code. BY the
looks of it it would seem that the proper send stream versioning could
be added first before any of this code lands. In this case we can simply
have the encoded writes stuff as protocol version 2 and leave the rest
of the commands for v3 for example.
The original idea for this was to minimize protocol revisions. This way,
when we get around to implementing fallocate on the send side, we
wouldn't need another update on the receive side. I still like that idea
since the receive side is so trivial.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help