Re: [PATCH 1/3] fstests: check btrfs profile configs before allowing raid56

Christoph Hellwig
2024-03-19T20:59:12Z

On Tue, Mar 19, 2024 at 12:55:56PM -0400, Josef Bacik wrote:
> +++ b/common/btrfs
> @@ -111,8 +111,12 @@ _require_btrfs_fs_feature()
> _notrun "Feature $feat not supported by the available btrfs version"
>
> if [ $feat = "raid56" ]; then
> - # Zoned btrfs only supports SINGLE profile
> - _require_non_zoned_device "${SCRATCH_DEV}"
> + # Make sure it's in our supported configs as well
> + _btrfs_get_profile_configs
> + if [[ ! "${_btrfs_profile_configs[@]}" =~ "raid5" ]] ||
> + [[ ! "${_btrfs_profile_configs[@]}" =~ "raid6" ]]; then
> + _notrun "raid56 excluded from profile configs"
> + fi

Should _require_btrfs_fs_feature check for raid5 and raid6 individually?
Right now it seems like you need both raid5 and raid6 in the profiles
to run checks that probably only exercise either?