summaryrefslogtreecommitdiffstats
path: root/sys/dev/vinum/vinumrequest.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/dev/vinum/vinumrequest.c')
-rw-r--r--sys/dev/vinum/vinumrequest.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/dev/vinum/vinumrequest.c b/sys/dev/vinum/vinumrequest.c
index 469d9cae..da7bff4 100644
--- a/sys/dev/vinum/vinumrequest.c
+++ b/sys/dev/vinum/vinumrequest.c
@@ -891,10 +891,10 @@ sdio(struct buf *bp)
if (drive->state != drive_up) {
if (sd->state >= sd_crashed) {
- if (bp->b_flags & B_WRITE) /* writing, */
- set_sd_state(sd->sdno, sd_stale, setstate_force);
- else
+ if (bp->b_flags & B_READ) /* reading, */
set_sd_state(sd->sdno, sd_crashed, setstate_force);
+ else
+ set_sd_state(sd->sdno, sd_stale, setstate_force);
}
bp->b_flags |= B_ERROR;
bp->b_error = EIO;
OpenPOWER on IntegriCloud