Changeset View
Changeset View
Standalone View
Standalone View
sys/geom/raid/tr_raid1e.c
Show First 20 Lines • Show All 1,038 Lines • ▼ Show 20 Lines | if (best >= 0 && (cbp = g_clone_bio(pbp)) != NULL) { | ||||
cbp->bio_ma = bp->bio_ma; | cbp->bio_ma = bp->bio_ma; | ||||
cbp->bio_ma_offset = bp->bio_ma_offset; | cbp->bio_ma_offset = bp->bio_ma_offset; | ||||
cbp->bio_ma_n = bp->bio_ma_n; | cbp->bio_ma_n = bp->bio_ma_n; | ||||
g_destroy_bio(bp); | g_destroy_bio(bp); | ||||
nsd = &vol->v_subdisks[disk]; | nsd = &vol->v_subdisks[disk]; | ||||
G_RAID_LOGREQ(2, cbp, "Retrying read from %d", | G_RAID_LOGREQ(2, cbp, "Retrying read from %d", | ||||
nsd->sd_pos); | nsd->sd_pos); | ||||
if (do_write) | if (do_write) | ||||
mask |= 1 << 31; | mask |= 1U << 31; | ||||
if ((mask & (1U << 31)) != 0) | if ((mask & (1U << 31)) != 0) | ||||
sd->sd_recovery++; | sd->sd_recovery++; | ||||
cbp->bio_caller2 = (void *)mask; | cbp->bio_caller2 = (void *)mask; | ||||
if (do_write) { | if (do_write) { | ||||
cbp->bio_caller1 = nsd; | cbp->bio_caller1 = nsd; | ||||
/* Lock callback starts I/O */ | /* Lock callback starts I/O */ | ||||
g_raid_lock_range(sd->sd_volume, | g_raid_lock_range(sd->sd_volume, | ||||
virtual, cbp->bio_length, pbp, cbp); | virtual, cbp->bio_length, pbp, cbp); | ||||
▲ Show 20 Lines • Show All 189 Lines • Show Last 20 Lines |