svn commit: r218450 - projects/graid/head/sys/geom/raid

Alexander Motin mav at FreeBSD.org
Tue Feb 8 19:36:23 UTC 2011


Author: mav
Date: Tue Feb  8 19:36:23 2011
New Revision: 218450
URL: http://svn.freebsd.org/changeset/base/218450

Log:
  Do not try to fail disk on rebuild write error if rebuild was aborted.
  If disk disappeared/replaced during write operation then attempt to fail
  it may target the innocent new disk or even placeholder.

Modified:
  projects/graid/head/sys/geom/raid/tr_raid1.c

Modified: projects/graid/head/sys/geom/raid/tr_raid1.c
==============================================================================
--- projects/graid/head/sys/geom/raid/tr_raid1.c	Tue Feb  8 19:28:13 2011	(r218449)
+++ projects/graid/head/sys/geom/raid/tr_raid1.c	Tue Feb  8 19:36:23 2011	(r218450)
@@ -683,7 +683,8 @@ g_raid_tr_iodone_raid1(struct g_raid_tr_
 				nsd = trs->trso_failed_sd;
 				if (bp->bio_error != 0 ||
 				    trs->trso_flags & TR_RAID1_F_ABORT) {
-					if (bp->bio_error != 0) {
+					if ((trs->trso_flags &
+					    TR_RAID1_F_ABORT) == 0) {
 						g_raid_fail_disk(sd->sd_softc,
 						    nsd, nsd->sd_disk);
 					}


More information about the svn-src-projects mailing list