From owner-freebsd-stable Sun Nov 26 5:23: 6 2000 Delivered-To: freebsd-stable@freebsd.org Received: from freebsd.dk (freebsd.dk [212.242.42.178]) by hub.freebsd.org (Postfix) with ESMTP id 08C4637B479 for ; Sun, 26 Nov 2000 05:23:03 -0800 (PST) Received: (from sos@localhost) by freebsd.dk (8.9.3/8.9.1) id OAA38044; Sun, 26 Nov 2000 14:23:26 +0100 (CET) (envelope-from sos) From: Soren Schmidt Message-Id: <200011261323.OAA38044@freebsd.dk> Subject: Re: 4.2-RELEASE ata0-master probe failed(solved) In-Reply-To: from Tai-hwa Liang at "Nov 26, 2000 08:14:38 pm" To: avatar@mmlab.cse.yzu.edu.tw (Tai-hwa Liang) Date: Sun, 26 Nov 2000 14:23:26 +0100 (CET) Cc: freebsd-stable@FreeBSD.org X-Mailer: ELM [version 2.4ME+ PL54 (25)] MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit Sender: owner-freebsd-stable@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG It seems Tai-hwa Liang wrote: > Hi, > > According to my injected debugging message, the first time > "inb(scp->altioaddr)" was executed in ata_intr(), it returns 0xd0(busy): Uhm 0xd0 is SERVICE and READY and BUSY, which doesn't make sense... > /* if drive is busy it didn't interrupt */ > if (inb(scp->altioaddr) & ATA_S_BUSY) > return; > > The booting message then said: "ata0-master: ata_comand: timeout > waiting for intr," and stopped to interact with my hard disk attached on > ata0-master anymore. However, if I forced an interrupt clear before busy > return, the timeout condition can be resolved & all further disk I/O > operations went normally: > > /* if drive is busy it didn't interrupt */ > if (inb(scp->altioaddr) & ATA_S_BUSY) > { > /* clear interrupt */ > inb(scp->ioaddr + ATA_STATUS); > return; > } This effectively disables the whole purpose of using the "alternative status" register. Using the alt reg does not clear the interrupt and we do not want to if this drive didn't interrupt. So this hack breaks the driver on systems with more than one controller on an interrupt (which is quiet common nowadays). Your problem might be that the altioaddr is not correct, so we get bogus status from it... > Include the above hacks, there are two other temporary "fixes" > against ata-all.c, 1.50.2.14. All of them work in my 4.2-R box. The first > is to replace the status checking routine in ata_intr() with the old one > (in 1.50.2.7): They are hard to read, they are mostly just whitespace pollution, the only real changes I see is the above, which wont work unfortunately... -Søren To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-stable" in the body of the message