From owner-freebsd-hackers Tue Oct 24 3:22:28 2000 Delivered-To: freebsd-hackers@freebsd.org Received: from c3-dbn-41.dial-up.net (c3-dbn-41.dial-up.net [196.33.200.41]) by hub.freebsd.org (Postfix) with ESMTP id 6C03A37B479 for ; Tue, 24 Oct 2000 03:22:17 -0700 (PDT) Received: (from rnordier@localhost) by siri.nordier.com (8.9.3/8.6.12) id MAA16016; Tue, 24 Oct 2000 12:20:53 +0200 (SAST) From: Robert Nordier Message-Id: <200010241020.MAA16016@siri.nordier.com> Subject: Re: Conflicting C/H/S values To: tpnelson@echidna.stu.cowan.edu.au (Trent Nelson) Date: Tue, 24 Oct 2000 12:20:53 +0200 (SAST) Cc: hackers@FreeBSD.ORG In-Reply-To: <39F2D320.74A760FF@echidna.stu.cowan.edu.au> from "Trent Nelson" at Oct 22, 2000 07:44:32 PM X-Mailer: ELM [version 2.5 PL3] MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Trent Nelson wrote: > Could someone explain to me why the following HDD BIOS Geometries don't > represent the values proposed by the drives. What am I missing? > > (snippets from boot -v) > > BIOS Geometries: > 0:030c7f3f 0..780=781 cylinders, 0..127=128 heads, 1..63=63 sectors > 1:03fefe3f 0..1022=1023 cylinders, 0..254=255 heads, 1..63=63 sectors > 2:03fefe3f 0..1022=1023 cylinders, 0..254=255 heads, 1..63=63 sectors > 3:026dfe3f 0..621=622 cylinders, 0..254=255 heads, 1..63=63 sectors > 0 accounted for > > These don't correlate to the C/H/S values proposed by the drives: > > ad0: 8063MB (16514064 sectors), 16383 cyls, 16 heads, 63 S/T, 512 B/S > ad1: 9787MB (20044080 sectors), 19885 cyls, 16 heads, 63 S/T, 512 B/S > ad2: 3079MB (6306048 sectors), 6256 cyls, 16 heads, 63 S/T, 512 B/S > ad3: 4892MB (10018890 sectors), 10602 cyls, 15 heads, 63 S/T, 512 B/S > > I'm running 5.0 as of mid-September, but I don't think that's the issue > as Windows tends to exhibit the same behaviour. The way the PC BIOS CHS disk interface was designed, too few cylinders (1024) and too many heads (256) are supported, compared with the geometry disk drives pretend to have nowadays. So most modern BIOSes do translation by default, representing 6256 cyls x 16 heads as (6256/8 x 16*8 =) 782 cyls x 128 heads. The off-by-one difference (782 vs. 781 given as BIOS geometry for drive 0) is due to reserving the last cylinder for diagnostics, etc., another BIOS quirk. -- Robert Nordier rnordier@nordier.com rnordier@FreeBSD.org To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message