btrfs: sysfs: export the balance paused state of exclusive operation
authorDavid Sterba <dsterba@suse.com>
Tue, 3 May 2022 15:35:25 +0000 (17:35 +0200)
committerDavid Sterba <dsterba@suse.com>
Thu, 5 May 2022 19:05:56 +0000 (21:05 +0200)
The new state allowing device addition with paused balance is not
exported to user space so it can't recognize it and actually start the
operation.

Fixes: efc0e69c2fea ("btrfs: introduce exclusive operation BALANCE_PAUSED state")
CC: stable@vger.kernel.org # 5.17
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/sysfs.c

index 17389a4..ba78ca5 100644 (file)
@@ -922,6 +922,9 @@ static ssize_t btrfs_exclusive_operation_show(struct kobject *kobj,
                case BTRFS_EXCLOP_BALANCE:
                        str = "balance\n";
                        break;
+               case BTRFS_EXCLOP_BALANCE_PAUSED:
+                       str = "balance paused\n";
+                       break;
                case BTRFS_EXCLOP_DEV_ADD:
                        str = "device add\n";
                        break;