summaryrefslogtreecommitdiffstats
path: root/sys/geom/part
diff options
context:
space:
mode:
authormarcel <marcel@FreeBSD.org>2009-01-06 06:47:53 +0000
committermarcel <marcel@FreeBSD.org>2009-01-06 06:47:53 +0000
commitd0347b328883650a39d35841feff58250976e6cf (patch)
tree8bd62a18b73c92a963a47d5f6d37d73d013c101b /sys/geom/part
parentbdafdcbcbb20409981a07f27f0ad95bb9e03e887 (diff)
downloadFreeBSD-src-d0347b328883650a39d35841feff58250976e6cf.zip
FreeBSD-src-d0347b328883650a39d35841feff58250976e6cf.tar.gz
Don't enforce an upper-bound to the number of sectors or heads
that that the provider has. The limits we imposed were PC BIOS specific and not always applicable.
Diffstat (limited to 'sys/geom/part')
-rw-r--r--sys/geom/part/g_part.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/sys/geom/part/g_part.c b/sys/geom/part/g_part.c
index ad84956..0ad3c61 100644
--- a/sys/geom/part/g_part.c
+++ b/sys/geom/part/g_part.c
@@ -182,10 +182,8 @@ g_part_geometry(struct g_part_table *table, struct g_consumer *cp,
u_int heads, sectors;
int idx;
- if (g_getattr("GEOM::fwsectors", cp, &sectors) != 0 ||
- sectors < 1 || sectors > 63 ||
- g_getattr("GEOM::fwheads", cp, &heads) != 0 ||
- heads < 1 || heads > 255) {
+ if (g_getattr("GEOM::fwsectors", cp, &sectors) != 0 || sectors == 0 ||
+ g_getattr("GEOM::fwheads", cp, &heads) != 0 || heads == 0) {
table->gpt_fixgeom = 0;
table->gpt_heads = 0;
table->gpt_sectors = 0;
OpenPOWER on IntegriCloud