From das@HAL9000.wox.org  Fri Jul  5 04:49:02 2002
Return-Path: <das@HAL9000.wox.org>
Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125])
	by hub.freebsd.org (Postfix) with ESMTP id D36FA37B401
	for <FreeBSD-gnats-submit@freebsd.org>; Fri,  5 Jul 2002 04:49:02 -0700 (PDT)
Received: from HAL9000.wox.org (12-233-156-170.client.attbi.com [12.233.156.170])
	by mx1.FreeBSD.org (Postfix) with ESMTP id DF54B43E58
	for <FreeBSD-gnats-submit@freebsd.org>; Fri,  5 Jul 2002 04:47:17 -0700 (PDT)
	(envelope-from das@HAL9000.wox.org)
Received: from HAL9000.wox.org (localhost [127.0.0.1])
	by HAL9000.wox.org (8.12.3/8.12.3) with ESMTP id g65Bl2Ne003381
	for <FreeBSD-gnats-submit@freebsd.org>; Fri, 5 Jul 2002 04:47:02 -0700 (PDT)
	(envelope-from das@HAL9000.wox.org)
Received: (from das@localhost)
	by HAL9000.wox.org (8.12.3/8.12.3/Submit) id g65Bl1iQ003380;
	Fri, 5 Jul 2002 04:47:01 -0700 (PDT)
	(envelope-from das)
Message-Id: <200207051147.g65Bl1iQ003380@HAL9000.wox.org>
Date: Fri, 5 Jul 2002 04:47:01 -0700 (PDT)
From: David Schultz <dschultz@uclink.Berkeley.EDU>
To: FreeBSD-gnats-submit@freebsd.org
Subject: ata driver incorrectly downgrades UDMA4 drives
X-Send-Pr-Version: 3.113
X-GNATS-Notify:

>Number:         40225
>Category:       kern
>Synopsis:       ata driver incorrectly downgrades UDMA4 drives
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    sos
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Fri Jul 05 04:50:01 PDT 2002
>Closed-Date:    Mon Apr 28 11:45:59 PDT 2003
>Last-Modified:  Mon Apr 28 11:45:59 PDT 2003
>Originator:     David Schultz
>Release:        FreeBSD 4.6-RELEASE i386
>Organization:
>Environment:
System: FreeBSD HAL9000.wox.org 4.6-RELEASE FreeBSD 4.6-RELEASE #5: Thu Jul 4 01:21:53 PDT 2002 root@HAL9000.wox.org:/usr/obj/usr/src/sys/HAL9000.natd i386

This problem occurs in -CURRENT and 4.6-RELEASE, but not in 4.5-RELEASE,
which leads me to believe that it is hiding in the ata code Sren MFC'd
on 3-18.

>Description:
My primary IDE controller has two drives, only one of which is
normally mounted.  The other one spins down after twenty minutes.
But if I suspend the system using either `zzz' or `acpiconf -s 1'
and then resume, the `sleeping' drive is downgraded to UDMA2 when
the controller is reset.  The exact message is:

        DMA limited to UDMA33, non-ATA66 cable or device

Both drives support UDMA4 and have worked fine for years.

>How-To-Repeat:
Maybe-interesting bits from dmesg follow.
ad1 is the drive I actually use.

atapci0: <VIA 82C596 ATA66 controller> port 0xd800-0xd80f at device 4.1 on pci0
ata0: at 0x1f0 irq 14 on atapci0
ata1: at 0x170 irq 15 on atapci0
...
ad0: 19595MB <QUANTUM FIREBALLP LM20.5> [39813/16/63] at ata0-master UDMA66
ad1: 17206MB <WDC AC418000D> [34960/16/63] at ata0-slave UDMA66
acd0: CD-RW <TDK CDRW161040X> at ata1-master WDMA2
acd1: DVD-ROM <TOSHIBA DVD-ROM SD-M1202> at ata1-slave WDMA2
Mounting root from ufs:/dev/ad1s1a

>Fix:
>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-bugs->sos 
Responsible-Changed-By: johan 
Responsible-Changed-When: Sat Aug 24 05:56:49 PDT 2002 
Responsible-Changed-Why:  
Over to ATA maintainer. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=40225 

From: Giorgos Keramidas <keramida@freebsd.org>
To: bug-followup@freebsd.org
Cc:  
Subject: Re: kern/40225: ata driver incorrectly downgrades UDMA4 drives
Date: Mon, 24 Feb 2003 23:27:13 +0200

 # Adding to audit trail from pending/48557.
 
 : Message-Id: <20030222112002.GA71537@HAL9000.homeunix.com>
 : Date: Sat, 22 Feb 2003 03:20:02 -0800
 : From: David Schultz <dschultz@uclink.Berkeley.EDU>
 :
 : > My primary IDE controller has two drives, only one of which is
 : > normally mounted.  The other one spins down after twenty minutes.
 : > But if I suspend the system using either `zzz' or `acpiconf -s 1'
 : > and then resume, the `sleeping' drive is downgraded to UDMA2 when
 : > the controller is reset.  The exact message is:
 : >
 : >     DMA limited to UDMA33, non-ATA66 cable or device
 : >
 : > Both drives support UDMA4 and have worked fine for years.
 :
 : FYI, the new ATA code in -CURRENT solves this problem.  I would
 : have referenced this PR when I mailed you the fix the other
 : month, but I forgot I filed this!
 
 
 # Adding to audit trail from pending/48558.
 
 : Message-Id: <200302221156.h1MBuXQv094483@spider.deepcore.dk>
 : Date: Sat, 22 Feb 2003 12:56:33 +0100 (CET)
 : From: Soeren Schmidt <sos@spider.deepcore.dk>
 :
 : It seems David Schultz wrote:
 : > FYI, the new ATA code in -CURRENT solves this problem.  I would
 : > have referenced this PR when I mailed you the fix the other
 : > month, but I forgot I filed this!
 :
 : Okies, thanks for reporting back!
State-Changed-From-To: open->closed 
State-Changed-By: sos 
State-Changed-When: Mon Apr 28 11:45:11 PDT 2003 
State-Changed-Why:  
Problem fixed. 

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