HomeFreeBSD

linux: implement filesystem-side clone ioctls

Description

linux: implement filesystem-side clone ioctls

Prior to Linux 4.5, the FICLONE etc ioctls were specific to BTRFS, and
were implemented as regular filesystem-specific ioctls. This implements
those ioctls directly in OpenZFS, allowing cloning to work on older
kernels.

There's no need to gate these behind version checks; on later kernels
Linux will simply never deliver these ioctls, instead calling the
approprate VFS op.

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

Details

Provenance
rob.norris_klarasystems.comAuthored on Jun 27 2023, 1:45 PM
Brian Behlendorf <behlendorf1@llnl.gov>Committed on Jul 26 2023, 3:46 PM
Parents
rG5d12545da8c1: linux: implement filesystem-side copy/clone functions
Branches
Unknown
Tags
Unknown