HomeFreeBSD

zfs_clone_range should return a descriptive error codes

Description

zfs_clone_range should return a descriptive error codes

Return the more descriptive error codes instead of EXDEV when
the parameters don't match the requirements of the clone function.
Updated the comments in brt.c accordingly.
The first three errors are just invalid parameters, which zfs can
not handle.
The fourth error indicates that the block which should be cloned
is created and cloned or modified in the same transaction
group (txg).

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: Rob Norris <rob.norris@klarasystems.com>
Signed-off-by: Kay Pedersen <mail@mkwg.de>
Closes #15148

Details

Provenance
oromenahar <christianpe96@gmail.com>Authored on Aug 8 2023, 4:37 PM
GitHub <noreply@github.com>Committed on Aug 8 2023, 4:37 PM
Parents
rG683edb32b738: libzfs: sendrecv: send_progress_thread: handle SIGINFO/SIGUSR1
Branches
Unknown
Tags
Unknown