Changeset View
Changeset View
Standalone View
Standalone View
head/sys/geom/raid3/g_raid3.c
Show First 20 Lines • Show All 2,121 Lines • ▼ Show 20 Lines | if (bp->bio_from->geom == sc->sc_sync.ds_geom && | ||||
g_raid3_sync_request(bp); /* READ */ | g_raid3_sync_request(bp); /* READ */ | ||||
} else if (bp->bio_to != sc->sc_provider) { | } else if (bp->bio_to != sc->sc_provider) { | ||||
if ((bp->bio_cflags & G_RAID3_BIO_CFLAG_REGULAR) != 0) | if ((bp->bio_cflags & G_RAID3_BIO_CFLAG_REGULAR) != 0) | ||||
g_raid3_regular_request(bp); | g_raid3_regular_request(bp); | ||||
else if ((bp->bio_cflags & G_RAID3_BIO_CFLAG_SYNC) != 0) | else if ((bp->bio_cflags & G_RAID3_BIO_CFLAG_SYNC) != 0) | ||||
g_raid3_sync_request(bp); /* WRITE */ | g_raid3_sync_request(bp); /* WRITE */ | ||||
else { | else { | ||||
KASSERT(0, | KASSERT(0, | ||||
("Invalid request cflags=0x%hhx to=%s.", | ("Invalid request cflags=0x%hx to=%s.", | ||||
bp->bio_cflags, bp->bio_to->name)); | bp->bio_cflags, bp->bio_to->name)); | ||||
} | } | ||||
} else if (g_raid3_register_request(bp) != 0) { | } else if (g_raid3_register_request(bp) != 0) { | ||||
mtx_lock(&sc->sc_queue_mtx); | mtx_lock(&sc->sc_queue_mtx); | ||||
bioq_insert_head(&sc->sc_queue, bp); | bioq_insert_head(&sc->sc_queue, bp); | ||||
/* | /* | ||||
* We are short in memory, let see if there are finished | * We are short in memory, let see if there are finished | ||||
* request we can free. | * request we can free. | ||||
▲ Show 20 Lines • Show All 1,448 Lines • Show Last 20 Lines |