btrfs-progs: subvolume: use BTRFS_IOC_SUBVOL_SYNC_WAIT for sync
This patch uses BTRFS_IOC_SUBVOL_SYNC_WAIT ioctl in subvolume sync command before checking periodically and adds an option to not to use sync wait ioctl call and force to check periodically. This patch calls a new function wait_for_subvolume_sync() that calls BTRFS_IOC_SUBVOL_SYNC_WAIT for each subvol.
Issue: #953
Thanks, this is still missing some usability bits. The new ioctl should be preferred if it exists, there's a mode to check it. Either it works or its -ENOTTY. The force argument is misleading, both ways work but with different capabilities. This should be explained in the help text and documentation.
Hi, @kdave ! Thanks for a comment. I've fixed this.
- print error message for
-ENOTTY - force_to_check -> periodic
- change usage message for this patch
Thanks, added to devel.