Adds comments about BTRFS_FS_EXCL_OP to existing comments
about the device locks.

Signed-off-by: Anand Jain <anand.j...@oracle.com>
---
 fs/btrfs/volumes.c | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

diff --git a/fs/btrfs/volumes.c b/fs/btrfs/volumes.c
index 3a3912a9dec9..18306165ffaa 100644
--- a/fs/btrfs/volumes.c
+++ b/fs/btrfs/volumes.c
@@ -202,6 +202,22 @@ static int __btrfs_map_block(struct btrfs_fs_info *fs_info,
  *   device_list_mutex
  *     chunk_mutex
  *   balance_mutex
+ *
+ * BTRFS_FS_EXCL_OP
+ * ----------------
+ * Maintains the exclusivity of the following device operations.
+ *
+ * - Balance (*)
+ * - Add
+ * - Remove
+ * - Replace (*)
+ * - Resize
+ *
+ * The device operation with (*) indicate it can continue after a CLI pause
+ * (only balance can be paused using CLI) or remount or unmount-mount sequence
+ * or a power-recycle, as long as the FS is still writeable. And during the
+ * course of the pause, the BTRFS_FS_EXCL_OP remains set. BTRFS_FS_EXCL_OP flag
+ * is set and cleared using atomic functions.
  */
 
 DEFINE_MUTEX(uuid_mutex);
-- 
2.15.0

--
To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to