summaryrefslogtreecommitdiffstats
path: root/sys/geom/raid/tr_raid1.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/geom/raid/tr_raid1.c')
-rw-r--r--sys/geom/raid/tr_raid1.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/geom/raid/tr_raid1.c b/sys/geom/raid/tr_raid1.c
index ff5e5cd..4465e32 100644
--- a/sys/geom/raid/tr_raid1.c
+++ b/sys/geom/raid/tr_raid1.c
@@ -891,10 +891,10 @@ rebuild_round_done:
g_raid_unlock_range(sd->sd_volume, bp->bio_offset,
bp->bio_length);
}
- if (pbp->bio_cmd == BIO_WRITE) {
+ if (pbp->bio_cmd != BIO_READ) {
if (pbp->bio_inbed == 1 || pbp->bio_error != 0)
pbp->bio_error = bp->bio_error;
- if (bp->bio_error != 0) {
+ if (pbp->bio_cmd == BIO_WRITE && bp->bio_error != 0) {
G_RAID_LOGREQ(0, bp, "Write failed: failing subdisk.");
g_raid_tr_raid1_fail_disk(sd->sd_softc, sd, sd->sd_disk);
}
OpenPOWER on IntegriCloud