From nobody@FreeBSD.org  Sun Apr  9 19:43:35 2000
Return-Path: <nobody@FreeBSD.org>
Received: from freefall.freebsd.org (freefall.FreeBSD.ORG [204.216.27.21])
	by hub.freebsd.org (Postfix) with ESMTP id D9DCB37B7A6
	for <freebsd-gnats-submit@FreeBSD.org>; Sun,  9 Apr 2000 19:43:34 -0700 (PDT)
	(envelope-from nobody@FreeBSD.org)
Received: (from nobody@localhost)
	by freefall.freebsd.org (8.9.3/8.9.2) id TAA94671;
	Sun, 9 Apr 2000 19:43:34 -0700 (PDT)
	(envelope-from nobody@FreeBSD.org)
Message-Id: <200004100243.TAA94671@freefall.freebsd.org>
Date: Sun, 9 Apr 2000 19:43:34 -0700 (PDT)
From: asherrod@sharemedia.com
Sender: nobody@FreeBSD.org
To: freebsd-gnats-submit@FreeBSD.org
Subject: Still having trouble identifying disk geometry (in ata-disk.c now)
X-Send-Pr-Version: www-1.0

>Number:         17890
>Category:       i386
>Synopsis:       Still having trouble identifying disk geometry (in ata-disk.c now)
>Confidential:   no
>Severity:       serious
>Priority:       high
>Responsible:    sos
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sun Apr  9 19:50:07 PDT 2000
>Closed-Date:    Tue Nov 14 00:43:40 PST 2000
>Last-Modified:  Tue Nov 14 00:45:01 PST 2000
>Originator:     Andrew Sherrod
>Release:        4.0
>Organization:
Sharemedia
>Environment:
FreeBSD 4.0-RELEASE FreeBSD 4.0-RELEASE #0: Mon Apr 10 20:21:45 EDT 2000
root@parzival.radiojackboot.com:/usr/src/sys/compile/PARZIVAL i386
>Description:
This problem existed in wd.c and was carried over to ata-disk.c.

I have been told over and over it is not a "real" problem. Asking 
various users, I have discovered that I am not alone in experiencing 
this. Of course, others just followed the "Well, add a DOS partition,
and let Microsoft fix your problem" advice. But it IS a problem.

Whenever I install I have to go back and re-write the disk driver then
re-run newfs, etc... It is a problem. It can be fixed (easily).

My drives are not antiques or that unusual. One Western Digital, one
Maxtor. Okay, cheap disks, but not uncommon.

The problem: Not all disks return 16383 cylinders to indicate LBA mode
must be used. Mine return 4192, which rsults in rather small disk sizes.


>How-To-Repeat:
Boot the system with one of the disks in question. Try running 
/stand/sysinstall. Look at how small the disks just became.
>Fix:
129c129,130
< if(AD_PARAM->cylinder = 16383 && adp->total_sec < AD_PARAM->lbasize)
---
> if((AD_PARAM->cylinder == 16383 || AD_PARAM->lbaflag)
>    && adp->total_sec < AD_PARAM->lbasize)

>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-bugs->sos 
Responsible-Changed-By: grog 
Responsible-Changed-When: Sun Apr 9 21:41:12 PDT 2000 
Responsible-Changed-Why:  
sos handles the ata driver. 
State-Changed-From-To: open->closed 
State-Changed-By: sos 
State-Changed-When: Tue Nov 14 00:43:40 PST 2000 
State-Changed-Why:  
Hmm, this is a BIOS problem, and the fix here breaks other devices 
that report LBS without really supporting it. 
Please upgrade your BIOS.. 


http://www.freebsd.org/cgi/query-pr.cgi?pr=17890 
>Unformatted:
