From: Andre Noll <maan@systemlinux.org>
To: Neil Brown <neilb@suse.de>
Cc: linux-raid@vger.kernel.org
Subject: Re: [PATCH] relax checks to support 3disk raid6 arrays
Date: Fri, 20 Mar 2009 10:14:36 +0100 [thread overview]
Message-ID: <20090320091436.GM17185@skl-net.de> (raw)
In-Reply-To: <18882.57018.465098.201167@notabene.brown>
[-- Attachment #1.1: Type: text/plain, Size: 439 bytes --]
On 11:09, Neil Brown wrote:
> Have you tried a 3-disk raid6 yet? Any conclusions?
Yes, I played around a bit and used the two attached patches that
relax some checks in the kernel and in mdadm. It appears to work fine,
but I did only minimal testing with small loop devices, so I would
not recommend it for production use yet :)
Regards
Andre
--
The only person who always got his work done by Friday was Robinson Crusoe
[-- Attachment #1.2: 3disk-raid6-kernel.patch --]
[-- Type: text/plain, Size: 2038 bytes --]
diff --git a/crypto/async_tx/async_pq.c b/crypto/async_tx/async_pq.c
index f375a27..2922e9f 100644
--- a/crypto/async_tx/async_pq.c
+++ b/crypto/async_tx/async_pq.c
@@ -395,7 +395,7 @@ async_pq_zero_sum(struct page **blocks, unsigned int offset, int src_cnt,
struct dma_async_tx_descriptor *tx = NULL;
enum dma_ctrl_flags dma_flags = cb_fn ? DMA_PREP_INTERRUPT : 0;
- BUG_ON(src_cnt < 2);
+ BUG_ON(src_cnt < 1);
if (device && src_cnt <= dma_maxpq(device, 0) - 2) {
dma_addr_t dma_src[src_cnt + 2];
@@ -486,7 +486,7 @@ async_syndrome_zero_sum(struct page **blocks, unsigned int offset, int src_cnt,
struct dma_async_tx_descriptor *tx = NULL;
enum dma_ctrl_flags dma_flags = cb_fn ? DMA_PREP_INTERRUPT : 0;
- BUG_ON(src_cnt < 2);
+ BUG_ON(src_cnt < 1);
if (device && src_cnt <= dma_maxpq(device, 0) - 2) {
dma_addr_t dma_src[src_cnt + 2];
diff --git a/crypto/async_tx/async_xor.c b/crypto/async_tx/async_xor.c
index 50cd370..70869bb 100644
--- a/crypto/async_tx/async_xor.c
+++ b/crypto/async_tx/async_xor.c
@@ -183,7 +183,7 @@ async_xor(struct page *dest, struct page **src_list, unsigned int offset,
struct dma_chan *chan = async_tx_find_channel(depend_tx, DMA_XOR,
&dest, 1, src_list,
src_cnt, len);
- BUG_ON(src_cnt <= 1);
+ BUG_ON(src_cnt < 1);
if (chan) {
/* run the xor asynchronously */
diff --git a/drivers/md/raid5.c b/drivers/md/raid5.c
index a76ef52..5ce7090 100644
--- a/drivers/md/raid5.c
+++ b/drivers/md/raid5.c
@@ -4357,8 +4357,8 @@ static raid5_conf_t *setup_conf(mddev_t *mddev)
mdname(mddev), mddev->new_layout);
return ERR_PTR(-EIO);
}
- if (mddev->new_level == 6 && mddev->raid_disks < 4) {
- printk(KERN_ERR "raid6: not enough configured devices for %s (%d, minimum 4)\n",
+ if (mddev->new_level == 6 && mddev->raid_disks < 3) {
+ printk(KERN_ERR "raid6: not enough configured devices for %s (%d, minimum 3)\n",
mdname(mddev), mddev->raid_disks);
return ERR_PTR(-EINVAL);
}
[-- Attachment #1.3: 3disk-raid6-mdadm.patch --]
[-- Type: text/plain, Size: 410 bytes --]
diff --git a/Create.c b/Create.c
index 9e65d0a..bd79838 100644
--- a/Create.c
+++ b/Create.c
@@ -96,7 +96,7 @@ int Create(struct supertype *st, char *mddev, int mdfd,
Name ": a RAID level is needed to create an array.\n");
return 1;
}
- if (raiddisks < 4 && level == 6) {
+ if (raiddisks < 3 && level == 6) {
fprintf(stderr,
Name ": at least 4 raid-devices needed for level 6\n");
return 1;
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 189 bytes --]
next prev parent reply other threads:[~2009-03-20 9:14 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-03-18 12:53 [PATCH] md: raid5 run(): Fix max_degraded for raid level 4 Andre Noll
2009-03-20 0:09 ` Neil Brown
2009-03-20 9:14 ` Andre Noll [this message]
2009-03-20 9:20 ` [PATCH] relax checks to support 3disk raid6 arrays Peter Rabbitson
2009-03-20 9:29 ` Andre Noll
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=20090320091436.GM17185@skl-net.de \
--to=maan@systemlinux.org \
--cc=linux-raid@vger.kernel.org \
--cc=neilb@suse.de \
/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).