summaryrefslogtreecommitdiffstats
path: root/sys/geom
diff options
context:
space:
mode:
authorae <ae@FreeBSD.org>2011-11-28 12:38:24 +0000
committerae <ae@FreeBSD.org>2011-11-28 12:38:24 +0000
commita267596c2aa9567b90bbb57c35c4720ce61b3f5f (patch)
tree9d1aa555cc3b99074132547b53f494845ecdde39 /sys/geom
parent1d0a25d803102d90071835783e60c1914af2349f (diff)
downloadFreeBSD-src-a267596c2aa9567b90bbb57c35c4720ce61b3f5f.zip
FreeBSD-src-a267596c2aa9567b90bbb57c35c4720ce61b3f5f.tar.gz
The size of APM could be bigger than number of already allocated entries.
And the first usable sector should not start from the inside of APM area. MFC after: 1 month
Diffstat (limited to 'sys/geom')
-rw-r--r--sys/geom/part/g_part_apm.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/geom/part/g_part_apm.c b/sys/geom/part/g_part_apm.c
index cd318c7..db789c1 100644
--- a/sys/geom/part/g_part_apm.c
+++ b/sys/geom/part/g_part_apm.c
@@ -443,7 +443,7 @@ g_part_apm_read(struct g_part_table *basetable, struct g_consumer *cp)
table = (struct g_part_apm_table *)basetable;
- basetable->gpt_first = table->self.ent_pmblkcnt + 1;
+ basetable->gpt_first = table->self.ent_size + 1;
basetable->gpt_last = table->ddr.ddr_blkcount - 1;
basetable->gpt_entries = table->self.ent_pmblkcnt - 1;
OpenPOWER on IntegriCloud