Re: [PATCH 1/2] common/xfs: _notrun tests that fail due to block size < sector size

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Oct 16, 2024 at 04:15:16PM -0700, Darrick J. Wong wrote:
> From: Darrick J. Wong <djwong@xxxxxxxxxx>
> 
> It makes no sense to fail a test that failed to format a filesystem with
> a block size smaller than the sector size since the test preconditions
> are not valid.
> 
> Signed-off-by: Darrick J. Wong <djwong@xxxxxxxxxx>
> ---

Makes sense to me,
Reviewed-by: Zorro Lang <zlang@xxxxxxxxxx>

>  common/xfs |    5 +++++
>  1 file changed, 5 insertions(+)
> 
> 
> diff --git a/common/xfs b/common/xfs
> index 62e3100ee117a7..53d55f9907fbb0 100644
> --- a/common/xfs
> +++ b/common/xfs
> @@ -172,6 +172,11 @@ _try_scratch_mkfs_xfs()
>  		mkfs_status=$?
>  	fi
>  
> +	if [ $mkfs_status -ne 0 ] && grep -q '^block size [0-9]* cannot be smaller than sector size' "$tmp.mkfserr"; then
> +		errormsg="$(grep '^block size [0-9]* cannot be smaller than sector size' "$tmp.mkfserr" | head -n 1)"
> +		_notrun "_scratch_mkfs_xfs: $errormsg"
> +	fi
> +
>  	# output mkfs stdout and stderr
>  	cat $tmp.mkfsstd
>  	cat $tmp.mkfserr >&2
> 





[Index of Archives]     [XFS Filesystem Development (older mail)]     [Linux Filesystem Development]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux RAID]     [Linux SCSI]


  Powered by Linux