Changeset View
Changeset View
Standalone View
Standalone View
sys/geom/raid/g_raid.c
Show First 20 Lines • Show All 947 Lines • ▼ Show 20 Lines | // return; | ||||
G_RAID_DEBUG1(1, sc, "Volume %s marked as dirty.", | G_RAID_DEBUG1(1, sc, "Volume %s marked as dirty.", | ||||
vol->v_name); | vol->v_name); | ||||
g_raid_write_metadata(sc, vol, NULL, NULL); | g_raid_write_metadata(sc, vol, NULL, NULL); | ||||
} | } | ||||
void | void | ||||
g_raid_tr_flush_common(struct g_raid_tr_object *tr, struct bio *bp) | g_raid_tr_flush_common(struct g_raid_tr_object *tr, struct bio *bp) | ||||
{ | { | ||||
struct g_raid_softc *sc; | |||||
struct g_raid_volume *vol; | struct g_raid_volume *vol; | ||||
struct g_raid_subdisk *sd; | struct g_raid_subdisk *sd; | ||||
struct bio_queue_head queue; | struct bio_queue_head queue; | ||||
struct bio *cbp; | struct bio *cbp; | ||||
int i; | int i; | ||||
vol = tr->tro_volume; | vol = tr->tro_volume; | ||||
sc = vol->v_softc; | |||||
/* | /* | ||||
* Allocate all bios before sending any request, so we can return | * Allocate all bios before sending any request, so we can return | ||||
* ENOMEM in nice and clean way. | * ENOMEM in nice and clean way. | ||||
*/ | */ | ||||
bioq_init(&queue); | bioq_init(&queue); | ||||
for (i = 0; i < vol->v_disks_count; i++) { | for (i = 0; i < vol->v_disks_count; i++) { | ||||
sd = &vol->v_subdisks[i]; | sd = &vol->v_subdisks[i]; | ||||
▲ Show 20 Lines • Show All 1,603 Lines • Show Last 20 Lines |