linux-raid.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Logan Gunthorpe <logang@deltatee.com>
To: linux-raid@vger.kernel.org, Jes Sorensen <jsorensen@fb.com>
Cc: Song Liu <song@kernel.org>, Christoph Hellwig <hch@infradead.org>,
	Donald Buczek <buczek@molgen.mpg.de>,
	Guoqing Jiang <guoqing.jiang@linux.dev>, Xiao Ni <xni@redhat.com>,
	Himanshu Madhani <himanshu.madhani@oracle.com>,
	Mariusz Tkaczyk <mariusz.tkaczyk@linux.intel.com>,
	Coly Li <colyli@suse.de>, Bruce Dubbs <bruce.dubbs@gmail.com>,
	Stephen Bates <sbates@raithlin.com>,
	Martin Oliveira <Martin.Oliveira@eideticom.com>,
	David Sloan <David.Sloan@eideticom.com>,
	Sudhakar Panneerselvam <sudhakar.panneerselvam@oracle.com>,
	Logan Gunthorpe <logang@deltatee.com>
Subject: [PATCH mdadm v2 09/14] tests: fix raid0 tests for 0.90 metadata
Date: Wed, 22 Jun 2022 14:25:14 -0600	[thread overview]
Message-ID: <20220622202519.35905-10-logang@deltatee.com> (raw)
In-Reply-To: <20220622202519.35905-1-logang@deltatee.com>

From: Sudhakar Panneerselvam <sudhakar.panneerselvam@oracle.com>

Some of the test cases fail because raid0 creation fails with the error,
"0.90 metadata does not support layouts for RAID0" added by commit,
329dfc28debb. Fix some of the test cases by switching from raid0 to
linear level for 0.9 metadata where possible.

Signed-off-by: Sudhakar Panneerselvam <sudhakar.panneerselvam@oracle.com>
Signed-off-by: Himanshu Madhani <himanshu.madhani@oracle.com>
Signed-off-by: Logan Gunthorpe <logang@deltatee.com>
---
 tests/00raid0           | 4 ++--
 tests/00readonly        | 4 ++++
 tests/03r0assem         | 6 +++---
 tests/04r0update        | 4 ++--
 tests/04update-metadata | 2 +-
 5 files changed, 12 insertions(+), 8 deletions(-)

diff --git a/tests/00raid0 b/tests/00raid0
index e6b21cc419eb..9b8896cbdc52 100644
--- a/tests/00raid0
+++ b/tests/00raid0
@@ -20,8 +20,8 @@ mdadm -S $md0
 # now same again with different chunk size
 for chunk in 4 32 256
 do
-  mdadm -CR $md0 -e0.90 -l raid0 --chunk $chunk -n3 $dev0 $dev1 $dev2
-  check raid0
+  mdadm -CR $md0 -e0.90 -l linear --chunk $chunk -n3 $dev0 $dev1 $dev2
+  check linear
   testdev $md0 3 $mdsize0 $chunk
   mdadm -S $md0
 
diff --git a/tests/00readonly b/tests/00readonly
index 28b0fa13f815..39202487f614 100644
--- a/tests/00readonly
+++ b/tests/00readonly
@@ -4,6 +4,10 @@ for metadata in 0.9 1.0 1.1 1.2
 do
 	for level in linear raid0 raid1 raid4 raid5 raid6 raid10
 	do
+		if [[ $metadata == "0.9" && $level == "raid0" ]];
+		then
+			continue
+		fi
 		mdadm -CR $md0 -l $level -n 4 --metadata=$metadata \
 			$dev1 $dev2 $dev3 $dev4 --assume-clean
 		check nosync
diff --git a/tests/03r0assem b/tests/03r0assem
index 6744e3221062..44df06456233 100644
--- a/tests/03r0assem
+++ b/tests/03r0assem
@@ -68,9 +68,9 @@ mdadm -S $md2
 ### Now for version 0...
 
 mdadm --zero-superblock $dev0 $dev1 $dev2
-mdadm -CR $md2 -l0 --metadata=0.90 -n3 $dev0 $dev1 $dev2
-check raid0
-tst="testdev $md2 3 $mdsize0 512"
+mdadm -CR $md2 -llinear --metadata=0.90 -n3 $dev0 $dev1 $dev2
+check linear
+tst="testdev $md2 3 $mdsize0 1"
 $tst
 
 uuid=`mdadm -Db $md2 | sed 's/.*UUID=//'`
diff --git a/tests/04r0update b/tests/04r0update
index 73ee3b9fed91..b95efb06c761 100644
--- a/tests/04r0update
+++ b/tests/04r0update
@@ -1,7 +1,7 @@
 
 # create a raid0, re-assemble with a different super-minor
-mdadm -CR -e 0.90 $md0 -l0 -n3 $dev0 $dev1 $dev2
-testdev $md0 3 $mdsize0 512
+mdadm -CR -e 0.90 $md0 -llinear -n3 $dev0 $dev1 $dev2
+testdev $md0 3 $mdsize0 1
 minor1=`mdadm -E $dev0 | sed -n -e 's/.*Preferred Minor : //p'`
 mdadm -S /dev/md0
 
diff --git a/tests/04update-metadata b/tests/04update-metadata
index 232fc1ffff4b..08c14af7ed29 100644
--- a/tests/04update-metadata
+++ b/tests/04update-metadata
@@ -8,7 +8,7 @@ set -xe
 
 dlist="$dev0 $dev1 $dev2 $dev3"
 
-for ls in raid0/4 linear/4 raid1/1 raid5/3 raid6/2
+for ls in linear/4 raid1/1 raid5/3 raid6/2
 do
   s=${ls#*/} l=${ls%/*}
   mdadm -CR --assume-clean -e 0.90 $md0 --level $l -n 4 -c 64 $dlist
-- 
2.30.2


  parent reply	other threads:[~2022-06-22 20:25 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-06-22 20:25 [PATCH mdadm v2 00/14] Bug fixes and testing improvments Logan Gunthorpe
2022-06-22 20:25 ` [PATCH mdadm v2 01/14] Makefile: Don't build static build with everything and everything-test Logan Gunthorpe
2022-06-28  7:00   ` Mariusz Tkaczyk
2022-06-22 20:25 ` [PATCH mdadm v2 02/14] DDF: Cleanup validate_geometry_ddf_container() Logan Gunthorpe
2022-06-22 20:25 ` [PATCH mdadm v2 03/14] DDF: Fix NULL pointer dereference in validate_geometry_ddf() Logan Gunthorpe
2022-06-22 20:25 ` [PATCH mdadm v2 04/14] mdadm/Grow: Fix use after close bug by closing after fork Logan Gunthorpe
2022-06-28  7:02   ` Mariusz Tkaczyk
2022-06-22 20:25 ` [PATCH mdadm v2 05/14] monitor: Avoid segfault when calling NULL get_bad_blocks Logan Gunthorpe
2022-06-22 20:25 ` [PATCH mdadm v2 06/14] mdadm: Fix mdadm -r remove option regression Logan Gunthorpe
2022-06-28  7:03   ` Mariusz Tkaczyk
2022-06-22 20:25 ` [PATCH mdadm v2 07/14] mdadm: Fix optional --write-behind parameter Logan Gunthorpe
2022-06-22 20:25 ` [PATCH mdadm v2 08/14] tests/00raid0: add a test that validates raid0 with layout fails for 0.9 Logan Gunthorpe
2022-06-22 20:25 ` Logan Gunthorpe [this message]
2022-06-22 20:25 ` [PATCH mdadm v2 10/14] tests/04update-metadata: avoid passing chunk size to raid1 Logan Gunthorpe
2022-06-22 20:25 ` [PATCH mdadm v2 11/14] tests/02lineargrow: clear the superblock at every iteration Logan Gunthorpe
2022-06-22 20:25 ` [PATCH mdadm v2 12/14] mdadm/test: Add a mode to repeat specified tests Logan Gunthorpe
2022-06-22 20:25 ` [PATCH mdadm v2 13/14] mdadm/test: Mark and ignore broken test failures Logan Gunthorpe
2022-06-22 20:25 ` [PATCH mdadm v2 14/14] tests: Add broken files for all broken tests Logan Gunthorpe
2022-07-22 17:00 ` [PATCH mdadm v2 00/14] Bug fixes and testing improvments Himanshu Madhani
2022-07-23  6:21   ` Coly Li
2022-08-08 20:22     ` Himanshu Madhani
2022-08-07 20:35 ` Jes Sorensen
2022-08-08 15:46   ` Logan Gunthorpe

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20220622202519.35905-10-logang@deltatee.com \
    --to=logang@deltatee.com \
    --cc=David.Sloan@eideticom.com \
    --cc=Martin.Oliveira@eideticom.com \
    --cc=bruce.dubbs@gmail.com \
    --cc=buczek@molgen.mpg.de \
    --cc=colyli@suse.de \
    --cc=guoqing.jiang@linux.dev \
    --cc=hch@infradead.org \
    --cc=himanshu.madhani@oracle.com \
    --cc=jsorensen@fb.com \
    --cc=linux-raid@vger.kernel.org \
    --cc=mariusz.tkaczyk@linux.intel.com \
    --cc=sbates@raithlin.com \
    --cc=song@kernel.org \
    --cc=sudhakar.panneerselvam@oracle.com \
    --cc=xni@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).