diff --git a/sys/geom/mirror/g_mirror_ctl.c b/sys/geom/mirror/g_mirror_ctl.c index 529fff86b4d8..b9318e0faf94 100644 --- a/sys/geom/mirror/g_mirror_ctl.c +++ b/sys/geom/mirror/g_mirror_ctl.c @@ -413,6 +413,7 @@ again: } else { bzero(md.md_provider, sizeof(md.md_provider)); } + md.md_provsize = pp->mediasize; sector = g_malloc(pp->sectorsize, M_WAITOK); mirror_metadata_encode(&md, sector); error = g_write_data(disks[i].consumer, diff --git a/sys/geom/raid3/g_raid3_ctl.c b/sys/geom/raid3/g_raid3_ctl.c index 5a4a07bd2e6f..b83b933460d6 100644 --- a/sys/geom/raid3/g_raid3_ctl.c +++ b/sys/geom/raid3/g_raid3_ctl.c @@ -449,6 +449,7 @@ g_raid3_ctl_insert(struct gctl_req *req, struct g_class *mp) strlcpy(md.md_provider, pp->name, sizeof(md.md_provider)); else bzero(md.md_provider, sizeof(md.md_provider)); + md.md_provsize = pp->mediasize; sector = g_malloc(pp->sectorsize, M_WAITOK); raid3_metadata_encode(&md, sector); g_topology_unlock();