• Nikolay Borisov's avatar
    btrfs: allow device add if balance is paused · a174c0a2
    Nikolay Borisov authored
    Currently paused balance precludes adding a device since they are both
    considered exclusive ops and we can have at most one running at a time.
    This is problematic in case a filesystem encounters an ENOSPC situation
    while balance is running, in this case the only thing the user can do
    is mount the fs with "skip_balance" which pauses balance and delete some
    data to free up space for balance. However, it should be possible to add
    a new device when balance is paused.
    
    Fix this by allowing device add to proceed when balance is paused.
    Signed-off-by: default avatarNikolay Borisov <nborisov@suse.com>
    Reviewed-by: default avatarDavid Sterba <dsterba@suse.com>
    Signed-off-by: default avatarDavid Sterba <dsterba@suse.com>
    a174c0a2
ioctl.c 125 KB