Linux Btrfs filesystem development
 help / color / mirror / Atom feed
* [PATCH] btrfs: sysfs: export the balance paused state of exclusive operation
@ 2022-05-03 15:35 David Sterba
  2022-05-10  8:42 ` Nikolay Borisov
  2022-05-11  2:33 ` Anand Jain
  0 siblings, 2 replies; 3+ messages in thread
From: David Sterba @ 2022-05-03 15:35 UTC (permalink / raw)
  To: linux-btrfs

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 | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/fs/btrfs/sysfs.c b/fs/btrfs/sysfs.c
index 366424222b4f..92a1fa8e3da6 100644
--- a/fs/btrfs/sysfs.c
+++ b/fs/btrfs/sysfs.c
@@ -957,6 +957,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;
-- 
2.34.1


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

* Re: [PATCH] btrfs: sysfs: export the balance paused state of exclusive operation
  2022-05-03 15:35 [PATCH] btrfs: sysfs: export the balance paused state of exclusive operation David Sterba
@ 2022-05-10  8:42 ` Nikolay Borisov
  2022-05-11  2:33 ` Anand Jain
  1 sibling, 0 replies; 3+ messages in thread
From: Nikolay Borisov @ 2022-05-10  8:42 UTC (permalink / raw)
  To: David Sterba, linux-btrfs



On 3.05.22 г. 18:35 ч., David Sterba wrote:
> 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>

Reviewed-by: Nikolay Borisov <nborisov@suse.com>

> ---
>   fs/btrfs/sysfs.c | 3 +++
>   1 file changed, 3 insertions(+)
> 
> diff --git a/fs/btrfs/sysfs.c b/fs/btrfs/sysfs.c
> index 366424222b4f..92a1fa8e3da6 100644
> --- a/fs/btrfs/sysfs.c
> +++ b/fs/btrfs/sysfs.c
> @@ -957,6 +957,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;

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

* Re: [PATCH] btrfs: sysfs: export the balance paused state of exclusive operation
  2022-05-03 15:35 [PATCH] btrfs: sysfs: export the balance paused state of exclusive operation David Sterba
  2022-05-10  8:42 ` Nikolay Borisov
@ 2022-05-11  2:33 ` Anand Jain
  1 sibling, 0 replies; 3+ messages in thread
From: Anand Jain @ 2022-05-11  2:33 UTC (permalink / raw)
  To: David Sterba, linux-btrfs

On 5/3/22 21:05, David Sterba wrote:
> 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>

looks good.

Reviewed-by: Anand Jain <anand.jain@oracle.com>

> ---
>   fs/btrfs/sysfs.c | 3 +++
>   1 file changed, 3 insertions(+)
> 
> diff --git a/fs/btrfs/sysfs.c b/fs/btrfs/sysfs.c
> index 366424222b4f..92a1fa8e3da6 100644
> --- a/fs/btrfs/sysfs.c
> +++ b/fs/btrfs/sysfs.c
> @@ -957,6 +957,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;


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

end of thread, other threads:[~2022-05-11  2:47 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-05-03 15:35 [PATCH] btrfs: sysfs: export the balance paused state of exclusive operation David Sterba
2022-05-10  8:42 ` Nikolay Borisov
2022-05-11  2:33 ` Anand Jain

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox