summaryrefslogtreecommitdiffstats
path: root/sys/geom
diff options
context:
space:
mode:
authormarcel <marcel@FreeBSD.org>2009-02-17 04:12:10 +0000
committermarcel <marcel@FreeBSD.org>2009-02-17 04:12:10 +0000
commitf846049b94bb1e6a2a2554ae9fd291d67b34120f (patch)
treef08741222f256b5b53ec8bdf6801c173dc50cf5a /sys/geom
parent925ee6b32dd1cee487eed388595896d390b8096b (diff)
downloadFreeBSD-src-f846049b94bb1e6a2a2554ae9fd291d67b34120f.zip
FreeBSD-src-f846049b94bb1e6a2a2554ae9fd291d67b34120f.tar.gz
Remove gpt_offset and related code. It was introduced for use
by the BSD scheme, ended up not to be needed. Remove to avoid abuse and to keep the bloat to a minimum.
Diffstat (limited to 'sys/geom')
-rw-r--r--sys/geom/part/g_part.c19
-rw-r--r--sys/geom/part/g_part.h7
2 files changed, 0 insertions, 26 deletions
diff --git a/sys/geom/part/g_part.c b/sys/geom/part/g_part.c
index 7982945..f82958c 100644
--- a/sys/geom/part/g_part.c
+++ b/sys/geom/part/g_part.c
@@ -701,14 +701,6 @@ g_part_ctl_create(struct gctl_req *req, struct g_part_parms *gpp)
error = g_getattr("PART::depth", cp, &attr);
table->gpt_depth = (!error) ? attr + 1 : 0;
- /* If we're nested, get the absolute sector offset on disk. */
- if (table->gpt_depth) {
- error = g_getattr("PART::offset", cp, &attr);
- if (error)
- goto fail;
- table->gpt_offset = attr;
- }
-
/*
* Synthesize a disk geometry. Some partitioning schemes
* depend on it and since some file systems need it even
@@ -1488,14 +1480,6 @@ g_part_taste(struct g_class *mp, struct g_provider *pp, int flags __unused)
table = gp->softc;
- /* If we're nested, get the absolute sector offset on disk. */
- if (table->gpt_depth) {
- error = g_getattr("PART::offset", cp, &attr);
- if (error)
- goto fail;
- table->gpt_offset = attr;
- }
-
/*
* Synthesize a disk geometry. Some partitioning schemes
* depend on it and since some file systems need it even
@@ -1686,9 +1670,6 @@ g_part_start(struct bio *bp)
return;
if (g_handleattr_int(bp, "PART::depth", table->gpt_depth))
return;
- if (g_handleattr_int(bp, "PART::offset",
- table->gpt_offset + entry->gpe_start))
- return;
if (g_handleattr_str(bp, "PART::scheme",
table->gpt_scheme->name))
return;
diff --git a/sys/geom/part/g_part.h b/sys/geom/part/g_part.h
index 353063b6..504d8ae 100644
--- a/sys/geom/part/g_part.h
+++ b/sys/geom/part/g_part.h
@@ -104,13 +104,6 @@ struct g_part_table {
*/
uint32_t gpt_sectors;
uint32_t gpt_heads;
- /*
- * gpt_offset holds the absolute block address of the scheme
- * on disk. Some partitioning schemes (historically) use
- * absolute addressing. Relative addresses are obtained by
- * subtracting gpt_offset from the absolute addresses.
- */
- uint64_t gpt_offset;
int gpt_depth; /* Sub-partitioning level. */
int gpt_isleaf:1; /* Cannot be sub-partitioned. */
OpenPOWER on IntegriCloud