All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] xfs/191: skip tests on older xfsprogs
@ 2016-08-14 13:35 Xiao Yang
  2016-08-17  3:08 ` Xiao Yang
  0 siblings, 1 reply; 5+ messages in thread
From: Xiao Yang @ 2016-08-14 13:35 UTC (permalink / raw)
  To: fstests; +Cc: eguan, jtulak, root

From: root <root@localhost.localdomain>

If we don't have /tmp/foo file on xfsprogs 3.2.2, _require_xfs_mkfs_validation
will fail because mkfs.xfs can't create this file.  We need to skip tests
before xfsprogs 4.7.0, so fix it.  the feature has been introduced since
xfsprogs 4.2.0:
commit 20cec860e16b267ea0c71a2f648fa2b26aad2e65
Author: Eric Sandeen <sandeen@sandeen.net>
Date: Fri Jul 31 09:04:11 2015 +1000

  mkfs.xfs: always use underlying fs sector size when mkfs'ing a file

Signed-off-by: root <root@localhost.localdomain>
---
 common/rc | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/common/rc b/common/rc
index b19b698..db99794 100644
--- a/common/rc
+++ b/common/rc
@@ -3889,6 +3889,9 @@ _get_fs_sysfs_attr()
 # number of failed cases.
 _mkfs_validation_check()
 {
+	if [ ! -f /tmp/foo ]; then
+		touch /tmp/foo
+	fi
 	local cmd="$MKFS_XFS_PROG -f -N -d file,name=/tmp/foo,size=$((1024 * 1024 * 1024))"
 	$cmd -s size=2s >/dev/null 2>&1
 	local sum=$?
-- 
1.8.3.1




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

* Re: [PATCH] xfs/191: skip tests on older xfsprogs
  2016-08-14 13:35 [PATCH] xfs/191: skip tests on older xfsprogs Xiao Yang
@ 2016-08-17  3:08 ` Xiao Yang
  0 siblings, 0 replies; 5+ messages in thread
From: Xiao Yang @ 2016-08-17  3:08 UTC (permalink / raw)
  To: fstests; +Cc: jtulak

Sorry, please ingore it, I will resend it.
On 2016/08/14 21:35, Xiao Yang wrote:
> From: root <root@localhost.localdomain>
>
> If we don't have /tmp/foo file on xfsprogs 3.2.2, _require_xfs_mkfs_validation
> will fail because mkfs.xfs can't create this file.  We need to skip tests
> before xfsprogs 4.7.0, so fix it.  the feature has been introduced since
> xfsprogs 4.2.0:
> commit 20cec860e16b267ea0c71a2f648fa2b26aad2e65
> Author: Eric Sandeen <sandeen@sandeen.net>
> Date: Fri Jul 31 09:04:11 2015 +1000
>
>   mkfs.xfs: always use underlying fs sector size when mkfs'ing a file
>
> Signed-off-by: root <root@localhost.localdomain>
> ---
>  common/rc | 3 +++
>  1 file changed, 3 insertions(+)
>
> diff --git a/common/rc b/common/rc
> index b19b698..db99794 100644
> --- a/common/rc
> +++ b/common/rc
> @@ -3889,6 +3889,9 @@ _get_fs_sysfs_attr()
>  # number of failed cases.
>  _mkfs_validation_check()
>  {
> +	if [ ! -f /tmp/foo ]; then
> +		touch /tmp/foo
> +	fi
>  	local cmd="$MKFS_XFS_PROG -f -N -d file,name=/tmp/foo,size=$((1024 * 1024 * 1024))"
>  	$cmd -s size=2s >/dev/null 2>&1
>  	local sum=$?




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

* Re: [PATCH] xfs/191: skip tests on older xfsprogs
  2016-08-17  3:36 ` Eryu Guan
@ 2016-08-17  9:27   ` Jan Tulak
  0 siblings, 0 replies; 5+ messages in thread
From: Jan Tulak @ 2016-08-17  9:27 UTC (permalink / raw)
  To: Eryu Guan; +Cc: Xiao Yang, fstests

On Wed, Aug 17, 2016 at 5:36 AM, Eryu Guan <eguan@redhat.com> wrote:

>>  _mkfs_validation_check()
>>  {
>> +     if [ ! -f /tmp/foo ]; then
>> +             touch /tmp/foo
>> +     fi
>
> I think the file can be touched unconditionally.
>

If the file already exists and mtime/atime of the file is important,
then it could be an issue. It looks improbable, but still, maybe we
should be on the safe side?

Anyway, thanks for spotting this.

Jan

-- 
Jan Tulak
jtulak@redhat.com / jan@tulak.me

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

* Re: [PATCH] xfs/191: skip tests on older xfsprogs
  2016-08-17  3:18 Xiao Yang
@ 2016-08-17  3:36 ` Eryu Guan
  2016-08-17  9:27   ` Jan Tulak
  0 siblings, 1 reply; 5+ messages in thread
From: Eryu Guan @ 2016-08-17  3:36 UTC (permalink / raw)
  To: Xiao Yang; +Cc: fstests, jtulak

On Wed, Aug 17, 2016 at 11:18:55AM +0800, Xiao Yang wrote:
> If we don't have /tmp/foo file on xfsprogs 3.2.2, _require_xfs_mkfs_validation
> will fail because mkfs.xfs can't create this file.  We need to skip tests
> before xfsprogs 4.7.0, so fix it.  the feature has been introduced since
> xfsprogs 4.2.0:
> commit 20cec860e16b267ea0c71a2f648fa2b26aad2e65
> Author: Eric Sandeen <sandeen@sandeen.net>
> Date: Fri Jul 31 09:04:11 2015 +1000
> 
>   mkfs.xfs: always use underlying fs sector size when mkfs'ing a file
> 
> Signed-off-by: Xiao Yang <yangx.jy@cn.fujitsu.com>
> ---
>  common/rc | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/common/rc b/common/rc
> index b19b698..db99794 100644
> --- a/common/rc
> +++ b/common/rc
> @@ -3889,6 +3889,9 @@ _get_fs_sysfs_attr()
>  # number of failed cases.
>  _mkfs_validation_check()
>  {
> +	if [ ! -f /tmp/foo ]; then
> +		touch /tmp/foo
> +	fi

I think the file can be touched unconditionally.

Thanks,
Eryu

>  	local cmd="$MKFS_XFS_PROG -f -N -d file,name=/tmp/foo,size=$((1024 * 1024 * 1024))"
>  	$cmd -s size=2s >/dev/null 2>&1
>  	local sum=$?
> -- 
> 1.8.3.1
> 
> 
> 
> --
> To unsubscribe from this list: send the line "unsubscribe fstests" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* [PATCH] xfs/191: skip tests on older xfsprogs
@ 2016-08-17  3:18 Xiao Yang
  2016-08-17  3:36 ` Eryu Guan
  0 siblings, 1 reply; 5+ messages in thread
From: Xiao Yang @ 2016-08-17  3:18 UTC (permalink / raw)
  To: fstests; +Cc: jtulak, Xiao Yang

If we don't have /tmp/foo file on xfsprogs 3.2.2, _require_xfs_mkfs_validation
will fail because mkfs.xfs can't create this file.  We need to skip tests
before xfsprogs 4.7.0, so fix it.  the feature has been introduced since
xfsprogs 4.2.0:
commit 20cec860e16b267ea0c71a2f648fa2b26aad2e65
Author: Eric Sandeen <sandeen@sandeen.net>
Date: Fri Jul 31 09:04:11 2015 +1000

  mkfs.xfs: always use underlying fs sector size when mkfs'ing a file

Signed-off-by: Xiao Yang <yangx.jy@cn.fujitsu.com>
---
 common/rc | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/common/rc b/common/rc
index b19b698..db99794 100644
--- a/common/rc
+++ b/common/rc
@@ -3889,6 +3889,9 @@ _get_fs_sysfs_attr()
 # number of failed cases.
 _mkfs_validation_check()
 {
+	if [ ! -f /tmp/foo ]; then
+		touch /tmp/foo
+	fi
 	local cmd="$MKFS_XFS_PROG -f -N -d file,name=/tmp/foo,size=$((1024 * 1024 * 1024))"
 	$cmd -s size=2s >/dev/null 2>&1
 	local sum=$?
-- 
1.8.3.1




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

end of thread, other threads:[~2016-08-17  9:27 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-08-14 13:35 [PATCH] xfs/191: skip tests on older xfsprogs Xiao Yang
2016-08-17  3:08 ` Xiao Yang
2016-08-17  3:18 Xiao Yang
2016-08-17  3:36 ` Eryu Guan
2016-08-17  9:27   ` Jan Tulak

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.