Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 6 Jan 2009 06:47:53 +0000 (UTC)
From:      Marcel Moolenaar <marcel@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r186807 - head/sys/geom/part
Message-ID:  <200901060647.n066lrYg023850@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: marcel
Date: Tue Jan  6 06:47:53 2009
New Revision: 186807
URL: http://svn.freebsd.org/changeset/base/186807

Log:
  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.

Modified:
  head/sys/geom/part/g_part.c

Modified: head/sys/geom/part/g_part.c
==============================================================================
--- head/sys/geom/part/g_part.c	Tue Jan  6 01:58:45 2009	(r186806)
+++ head/sys/geom/part/g_part.c	Tue Jan  6 06:47:53 2009	(r186807)
@@ -182,10 +182,8 @@ g_part_geometry(struct g_part_table *tab
 	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;



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200901060647.n066lrYg023850>