Message ID | 20240802112730.3575159-1-maharmstone@fb.com (mailing list archive) |
---|---|
Headers | show |
Series | btrfs-progs: use libbtrfsutil for subvolume creation | expand |
On Fri, Aug 2, 2024 at 7:27 AM Mark Harmstone <maharmstone@fb.com> wrote: > > These patches are a resending of Omar Sandoval's patch from 2018, which > appears to have been overlooked [0], split up and rebased against the > current code. > > We change btrfs subvol create and btrfs subvol snapshot so that they use > libbtrfsutil rather than calling the ioctl directly. > > [0] https://lore.kernel.org/linux-btrfs/ab09ba595157b7fb6606814730508cae4da48caf.1516991902.git.osandov@fb.com/ > > Changelog: > * Fixed deprecated function names > * Fixed test failures (now returns correct return value on failure) > * Fixed this breaking fstest btrfs/300 (thanks Boris) > > Mark Harmstone (3): > btrfs-progs: use libbtrfsutil for btrfs subvolume create > btrfs-progs: use libbtrfsutil for btrfs subvolume snapshot > btrfs-progs: remove unused qgroup functions > > cmds/qgroup.c | 64 ---------------- > cmds/qgroup.h | 2 - > cmds/subvolume.c | 194 +++++++++++++++++++---------------------------- > 3 files changed, 76 insertions(+), 184 deletions(-) > > -- > 2.44.2 > > Series looks good to me. Reviewed-by: Neal Gompa <neal@gompa.dev>
在 2024/8/2 20:57, Mark Harmstone 写道: > These patches are a resending of Omar Sandoval's patch from 2018, which > appears to have been overlooked [0], split up and rebased against the > current code. > > We change btrfs subvol create and btrfs subvol snapshot so that they use > libbtrfsutil rather than calling the ioctl directly. > > [0] https://lore.kernel.org/linux-btrfs/ab09ba595157b7fb6606814730508cae4da48caf.1516991902.git.osandov@fb.com/ Since you're reviving the cleanups, you may also want to move some btrfs-progs' ioctl related functions to libbtrfsutils. One example is btrfs_lookup_uuid_subvol_item() and btrfs_lookup_uuid_received_subvol_item(). With them moved to libbtrfsutils, we can mark kernel-shared/uuid-tree.[ch] as fully cross-ported from kernel. Thanks, Qu > > Changelog: > * Fixed deprecated function names > * Fixed test failures (now returns correct return value on failure) > * Fixed this breaking fstest btrfs/300 (thanks Boris) > > Mark Harmstone (3): > btrfs-progs: use libbtrfsutil for btrfs subvolume create > btrfs-progs: use libbtrfsutil for btrfs subvolume snapshot > btrfs-progs: remove unused qgroup functions > > cmds/qgroup.c | 64 ---------------- > cmds/qgroup.h | 2 - > cmds/subvolume.c | 194 +++++++++++++++++++---------------------------- > 3 files changed, 76 insertions(+), 184 deletions(-) >
Thanks Qu, I'll have a look at them. Mark On 5/8/24 01:46, Qu Wenruo wrote: > Since you're reviving the cleanups, you may also want to move some > btrfs-progs' ioctl related functions to libbtrfsutils. > > One example is btrfs_lookup_uuid_subvol_item() and > btrfs_lookup_uuid_received_subvol_item(). > > With them moved to libbtrfsutils, we can mark > kernel-shared/uuid-tree.[ch] as fully cross-ported from kernel.