Subject: Re: Disk controller speeds?
To: John Klos <john@sixgirls.org>
From: Manuel Bouyer <bouyer@antioche.eu.org>
List: port-macppc
Date: 10/28/2002 20:17:49
On Mon, Oct 28, 2002 at 04:31:17AM -0500, John Klos wrote:
> Hi,
> 
> In my PM 9600, I have an Adaptec 2940UW and a PCI IDE controller with a
> CMD Technology PCI0648 controller. Both are running at speeds other than
> their default:
> 
> ahc0 at pci0 dev 13 function 0
> ahc0: interrupting at irq 23
> ahc0: aic7880 Wide Channel A, SCSI Id=7, 16/255 SCBs
> ...
> sd0 at scsibus0 target 0 lun 0: <IBM, DDYS-T18350N, S96H> SCSI3 0/direct fixed
> sd0: 17501 MB, 15110 cyl, 6 head, 395 sec, 512 bytes/sect x 35843670 sectors
> sd0: sync (100.0ns offset 8), 16-bit (20.000MB/s) transfers, tagged queueing
> 
> I was just using a Symbios card which used ultra SCSI speed (50 ns, wide),
> but I may need that elsewhere and I don't see why this Adaptec card won't
> do ultra speed. This Adaptec just came out of an i386 machine running
> NetBSD where it did the full 40 meg / sec.

This is because the Adaptec BIOS is not run on the Mac, and the driver
use values from the BIOS
yes, this should be fixed ...

> 
> Then, the IDE card:
> 
> pciide0 at pci1 dev 14 function 0: CMD Technology PCI0648 (rev. 0x01)
> pciide0: bus-master DMA support present
> pciide0: primary channel configured to native-PCI mode
> pciide0: using irq 28 for native-PCI interrupt
> wd0 at pciide0 channel 0 drive 0: <IC35L120AVVA07-0>
> wd0: drive supports 16-sector PIO transfers, LBA addressing
> wd0: 115 GB, 16383 cyl, 16 head, 63 sec, 512 bytes/sect x 241254720 sectors
> wd0: drive supports PIO mode 4, DMA mode 2, Ultra-DMA mode 5 (Ultra/100)
> wd0(pciide0:0:0): using PIO mode 4, Ultra-DMA mode 2 (Ultra/33) (using DMA data
> transfers)
> 
> This card is supposed to be a Ultra/66 card, but it's only using Ultra/33.
> I've looked at whatever documentation I could find regarding IDE flags,
> but came up with nothing; the code in sys/dev/pci/pciide.c appears to
> support up to mode 4, but I'm not clear about why the mode is limited.
> 
> I tried changing:
>            if (drvp->UDMA_mode > 2 &&
>              (pciide_pci_read(sc->sc_pc, sc->sc_tag,
>              CMD_BICSR) &
>              CMD_BICSR_80(chp->channel)) == 0)
>                drvp->UDMA_mode = 2;
> (line 2630) to:
>                drvp->UDMA_mode = 4;
> and got:
> wd0: drive supports PIO mode 4, DMA mode 2, Ultra-DMA mode 5 (Ultra/100)
> wd0(pciide0:0:0): using PIO mode 4, Ultra-DMA mode 4 (Ultra/66) (using DMA
> data transfers)
> 
> But, honestly, I don't know what CMD_BICSR and friends are, so I don't
> know why these tests are being performed and why UDMA_mode is being
> lowered.

This is supposed to tell whenever the IDE cable is 40 or 80 pin.
Ae you sure your cable is Ultra-66 capable ?

-- 
Manuel Bouyer <bouyer@antioche.eu.org>
--