Re: [PATCH 1/4] xfs/432: Skip this test for dax config and pagesize not equal to the specified block size

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



On Mon, Oct 11, 2021 at 01:25:49PM +0530, Anju T Sudhakar wrote:
> This test case passes 1k as the block size(to keep that as minimum),
> and hence it fails to mount with "-o dax" option on platforms where
> pageszie not equal to the specified block size. This leads to test
> case reported as "failed" with dax config.
> 
> So skip this test when dax is enabled.
> 
> Signed-off-by: Anju T Sudhakar <anju@xxxxxxxxxxxxxxxxxx>
> ---
>  tests/xfs/432 | 4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/tests/xfs/432 b/tests/xfs/432
> index 40cb2474..9022af69 100755
> --- a/tests/xfs/432
> +++ b/tests/xfs/432
> @@ -32,6 +32,10 @@ _require_scratch
>  
>  rm -f "$seqres.full"
>  
> +# Skip this test, if pagesize !=1k and dax is enabled.
> +if [[ $(get_page_size) -ne 1024 ]]; then
> +	_exclude_scratch_mount_option dax
> +fi

Page size will never be 1kB so there's no point even checking the
page size here.

The problem here is that exclusing the dax mount option is
completely wrong when "-o dax=never" is used - it means that even
though the storage hardware is DAX capable, don't use dax at all,
and so tests that use 1kB block sizes will actaully work.

IOWs, this test should run if dax=never or dax=inode is set, but not
if dax=always or just plain "dax" is set...

Cheers,

Dave.
-- 
Dave Chinner
david@xxxxxxxxxxxxx



[Index of Archives]     [Linux Filesystems Development]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux