From owner-freebsd-current Fri Jan 22 04:55:14 1999 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id EAA13069 for freebsd-current-outgoing; Fri, 22 Jan 1999 04:55:14 -0800 (PST) (envelope-from owner-freebsd-current@FreeBSD.ORG) Received: from godzilla.zeta.org.au (godzilla.zeta.org.au [203.26.10.9]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id EAA13064 for ; Fri, 22 Jan 1999 04:55:11 -0800 (PST) (envelope-from bde@godzilla.zeta.org.au) Received: (from bde@localhost) by godzilla.zeta.org.au (8.8.7/8.8.7) id XAA23422; Fri, 22 Jan 1999 23:54:59 +1100 Date: Fri, 22 Jan 1999 23:54:59 +1100 From: Bruce Evans Message-Id: <199901221254.XAA23422@godzilla.zeta.org.au> To: current@FreeBSD.ORG, dawes@rf900.physics.usyd.edu.au Subject: Re: Promise FastTrack PCI IDE controller Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG >I've been playing with a Promise FastTrack RAID (IDE) controller with >3.0-current as of yesterday. Although it is recognised in the PCI bus >probe as a "Promise Ultra/33" (it has the same vendor/chip ID as the >non-RAID card), the probes in i386/isa/wd.c fail. I added some debugging >printfs to the code, and have found that wdreset() is failing. By >changing the code to ignore that failure, it gets further, and correctly >identifies the attached disks. I can even access the disks sufficiently >to read the partition table with fdisk (but with timeouts). Errors in wdreset() for the Promise (at least for the Ultra/33) probably mean that du->dk_altport is not initialized properly. (Setting du->dk_altport is the only thing that is very special for the Promise, and wdreset() is the only function that uses du->dk_altport for anything except debugging.) The wrong setting of du->dk_altport may be caused by the section of code in pci/ide_pci.c described by "/* This code below is mighty bogus. ...". Bugs there may also break DMA capability. >... >promise_status: port0: 0xeff0, port0_alt: 0xefe4, port1: 0xefa8, port1_alt: 0xefe0 >... >wdc2: wdd_candma is set for ide_pci1 >wdc2: I/O to 0xeff0 does work >wdc2: reset failed If the main block of ports is really at 0xeff0, as it probably must be since something worked, the altport is probably at port 0xefe4 and initializing du->dk_altport to this manually should fix wdreset(). >ide_pci: generic_dmainit eff0:0: warning, IDE controller timing not set >wd4: wdsetmode() setting transfer mode to 22 I don't see how the Promise can work right if generic_dmainit() gets called. generic_dmainit() never sets UltraDMA mode. It only sets mode 22, which is twice as slow. There is no special support for seting the IDE controller timing for the Promise, so generic_dmainit() gets called unless the BIOS has already set the IDE controller timing. Bruce To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message