summaryrefslogtreecommitdiffstats
path: root/sys/geom/geom_bsd.c
diff options
context:
space:
mode:
authorphk <phk@FreeBSD.org>2002-06-05 20:30:36 +0000
committerphk <phk@FreeBSD.org>2002-06-05 20:30:36 +0000
commit7f7b291518b00d350eb19be5613ba5f44dea5db9 (patch)
treec00bb36b848696cccd66b1b04a81cc487a607ec9 /sys/geom/geom_bsd.c
parent93f29d8926acf7a0ce2ceaaef0c39ad3f11172c7 (diff)
downloadFreeBSD-src-7f7b291518b00d350eb19be5613ba5f44dea5db9.zip
FreeBSD-src-7f7b291518b00d350eb19be5613ba5f44dea5db9.tar.gz
Change the registration of magic spaces so it does its own memory management.
Sponsored by: DARPA & NAI Labs.
Diffstat (limited to 'sys/geom/geom_bsd.c')
-rw-r--r--sys/geom/geom_bsd.c16
1 files changed, 7 insertions, 9 deletions
diff --git a/sys/geom/geom_bsd.c b/sys/geom/geom_bsd.c
index 3e5ed6f..77f4214 100644
--- a/sys/geom/geom_bsd.c
+++ b/sys/geom/geom_bsd.c
@@ -339,19 +339,17 @@ g_bsd_taste(struct g_class *mp, struct g_provider *pp, int flags)
}
error = g_bsd_try(gsp, cp, secsize, ms, secsize);
if (!error) {
- g_new_magicspaces(gp, 4);
- g_add_magicspace(gp, 0, "boot1", 0, 512, 0);
- g_add_magicspace(gp, 1, "label", 512, 276, 0);
- g_add_magicspace(gp, 2, "fill0", 748, 236, 0);
- g_add_magicspace(gp, 3, "boot2", 1024, 7168, 0);
+ g_add_magicspace(gp, "boot1", 0, 512, 0);
+ g_add_magicspace(gp, "label", 512, 276, 0);
+ g_add_magicspace(gp, "fill0", 748, 236, 0);
+ g_add_magicspace(gp, "boot2", 1024, 7168, 0);
}
if (error) {
error = g_bsd_try(gsp, cp, secsize, ms, 64);
if (!error) {
- g_new_magicspaces(gp, 3);
- g_add_magicspace(gp, 0, "fill0", 0, 64, 0);
- g_add_magicspace(gp, 1, "label", 64, 276, 0);
- g_add_magicspace(gp, 2, "fill1", 340, 172, 0);
+ g_add_magicspace(gp, "fill0", 0, 64, 0);
+ g_add_magicspace(gp, "label", 64, 276, 0);
+ g_add_magicspace(gp, "fill1", 340, 172, 0);
}
}
if (error)
OpenPOWER on IntegriCloud