Thread (8 messages) 8 messages, 1 author, 2004-09-08
DORMANTno replies

[PATCH md 6 of 7] Fix two little bugs in raid10

From: NeilBrown <hidden>
Date: 2004-09-08 02:48:10

These can cause resync to spin when there is a faulty drive.

Signed-off-by: Neil Brown <redacted>

### Diffstat output
 ./drivers/md/raid10.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletion(-)

diff ./drivers/md/raid10.c~current~ ./drivers/md/raid10.c
--- ./drivers/md/raid10.c~current~	2004-09-08 11:57:21.000000000 +1000
+++ ./drivers/md/raid10.c	2004-09-08 11:58:02.000000000 +1000
@@ -1496,6 +1496,7 @@ static int sync_request(mddev_t *mddev, 
 					rdev_dec_pending(conf->mirrors[d].rdev, mddev);
 			}
 			put_buf(r10_bio);
+			biolist = NULL;
 			goto giveup;
 		}
 	}
@@ -1557,7 +1558,7 @@ static int sync_request(mddev_t *mddev, 
 		}
 	}
 
-	return nr_sectors;
+	return sectors_skipped + nr_sectors;
  giveup:
 	/* There is nowhere to write, so all non-sync
 	 * drives must be failed, so try the next chunk...
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help