linux-btrfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 0/1] Add qgroup_autoremove flag
@ 2017-09-17 22:07 Sargun Dhillon
  2017-09-17 22:08 ` [PATCH v2 1/1] btrfs: Add mechanism to configure automatic level-0 qgroup removal Sargun Dhillon
  0 siblings, 1 reply; 2+ messages in thread
From: Sargun Dhillon @ 2017-09-17 22:07 UTC (permalink / raw)
  To: linux-btrfs; +Cc: quwenruo.btrfs, dsterba

This patch makes it so level-0 qgroups are automatically deleted. The
flag that enables this behaviour is persisted in btrfs_qgroup_status_item.
Although, it may make sense to introduce a btrfs_qgroup_configuration_item,
it seems somewhat overkill to do that just for one simple knob that can
fit into the existing flags.

The reason why this is a sysfs knob, and not a mount option is because
qgroups have to be enabled after the first mount. Having to do a mount,
enable qgroups, flip the knob, and then remounting seems somewhat more
awkward than this single sysfs knob.

Changes since v1:
 * Move from mount option to sysfs knob
 * Persist the knob across remounts

Sargun Dhillon (1):
  btrfs: Add mechanism to configure automatic level-0 qgroup removal

 fs/btrfs/ctree.h                |  2 +-
 fs/btrfs/ioctl.c                | 14 +++++++
 fs/btrfs/sysfs.c                | 91 ++++++++++++++++++++++++++++++++++++-----
 include/uapi/linux/btrfs_tree.h |  7 ++++
 4 files changed, 103 insertions(+), 11 deletions(-)

-- 
2.11.0


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2017-09-17 22:08 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-09-17 22:07 [PATCH v2 0/1] Add qgroup_autoremove flag Sargun Dhillon
2017-09-17 22:08 ` [PATCH v2 1/1] btrfs: Add mechanism to configure automatic level-0 qgroup removal Sargun Dhillon

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).