Subject: Re: pciide changes & promise pciide support
To: Hal Murray , Manuel Bouyer <bouyer@antioche.lip6.fr>
From: Robert Elz <kre@munnari.OZ.AU>
List: current-users
Date: 08/12/1999 04:52:12
    Date:        Thu, 12 Aug 1999 02:08:04 +1000
    From:        Robert Elz <kre@munnari.OZ.AU>
    Message-ID:  <23167.934387684@munnari.OZ.AU>

  | It certainly seems to compile & run on 1.4 (or at least, 1.4 with KAME added
  | in,

Actually, that was a pure 1.4 Kernel, I'd forgotten where I put the KAME
one ... this time I use the KAME kernel (which, as expected, made no
difference).

I now have a DVD connected to the Promise 66 (all I could find at 02:00)

NetBSD 1.4 (FUCHSIA) #27: Thu Aug 12 04:31:23 EST 1999
    kre@fuchsia.cs.mu.OZ.AU:/home/kame/kit/sys/arch/i386/compile/FUCHSIA

(blather)

pciide1 at pci0 dev 15 function 0: Promise Ultra DMA/ATA66 Bus Master IDE Accelerator
pciide1: bus-master DMA support present
pciide1: primary channel configured to native-PCI mode
pciide1: using irq 11 for native-PCI interrupt
atapibus2 at pciide1 channel 0
cd1 at atapibus2 drive 0: <TOSHIBA DVD-ROM SD-M1202, 4900806121, 1020> type 5 cdrom removable
cd1: 32-bits data port
cd1: drive supports PIO mode 4, DMA mode 2
cd1(pciide1:0:0): using PIO mode 4, DMA mode 2 (using DMA data transfers)
pciide1: secondary channel configured to native-PCI mode
pciide1: disabling secondary channel (no drives)

which all looks good.

However, when I attempt to mount a cd in there, I get ...

pciide1:0:0: lost interrupt
        type: atapi
        c_bcount: 32
        c_skip: 0
wdc_atapi_intr: bad data phase DATAIN
pciide1:0:0: Bus-Master DMA error: missing interrupt, status=0x21
cd1: transfer error, downgrading to PIO mode 4
cd1(pciide1:0:0): using PIO mode 4
pciide1:0:0: lost interrupt
        type: atapi
        c_bcount: 14
        c_skip: 18
pciide1:0:0: lost interrupt
        type: atapi
        c_bcount: 0
        c_skip: 8
pciide1:0:0: lost interrupt
        type: atapi
        c_bcount: 0
        c_skip: 12
pciide1:0:0: lost interrupt
        type: atapi
        c_bcount: 0
        c_skip: 2048
pciide1:0:0: lost interrupt
        type: atapi
        c_bcount: 0
        c_skip: 2048
pciide1:0:0: lost interrupt
        type: atapi
        c_bcount: 0
        c_skip: 2048


Yet, despite all that, the mount actually worked ...

/dev/cd1a on /cdrom1 type cd9660 (local, nosuid, read-only)

Filesystem  1K-blocks     Used    Avail Capacity  Mounted on
/dev/cd1a      467966   467966        0   100%    /cdrom1

and I was able to list its root directory, etc - that is, data seems to
read off it OK, though very slowly (probably several timeouts and retries).

So, for the Promise 66 at least, it is very close, but not yet quite
perfect.   But given the extreme hack I did to get the controller recognised
at all, it is really a miracle, and due to some obviously excelllent code
underneath (earlier the mount was failing, after after those lost interrupt
messages, yet the kernel continued along just fine, which is much better
that some other systems I could name when handed some non-operational
hardware).

kre