Subject: Re: CDROM problems
To: Manuel Bouyer <bouyer@antioche.lip6.fr>
From: Roger Brooks <R.S.Brooks@liverpool.ac.uk>
List: port-i386
Date: 06/27/1999 22:02:02
On Thu, 17 Jun 1999, Manuel Bouyer wrote:

>On Tue, Jun 15, 1999 at 11:06:39PM +0100, Roger Brooks wrote:
>> [...]
>> Jun 14 19:33:37 tallis /netbsd: pciide0 at pci0 dev 7 function 1: VIA Technologies VT82C586A IDE Controller
>> Jun 14 19:33:37 tallis /netbsd: pciide0: bus-master DMA support present
>> Jun 14 19:33:37 tallis /netbsd: pciide0: primary channel configured to compatibility mode
>> Jun 14 19:33:37 tallis /netbsd: atapibus0 at pciide0 channel 0
>> Jun 14 19:33:37 tallis /netbsd: atapibus0 drive 1: cmdsz 0x0 drqtype 0x0
>> Jun 14 19:33:37 tallis /netbsd: cd0 at atapibus0 drive 1: <ATAPI CD-ROM DRIVE 32X MAXIMUM, , 322P> type 5 cdrom removable
>> Jun 14 19:33:37 tallis /netbsd: cd0: drive supports PIO mode 4, DMA mode 2, Ultra-DMA mode 2
>> Jun 14 19:33:37 tallis /netbsd: wd0 at pciide0 channel 0 drive 0: <FUJITSU MPB3043ATU E>
>> Jun 14 19:33:37 tallis /netbsd: wd0: drive supports 16-sector pio transfers, lba addressing
>> Jun 14 19:33:37 tallis /netbsd: wd0: 4125MB, 8940 cyl, 15 head, 63 sec, 512 bytes/sect x 8448300 sectors
>> Jun 14 19:33:37 tallis /netbsd: wd0: 32-bits data port
>> Jun 14 19:33:37 tallis /netbsd: wd0: drive supports PIO mode 4, DMA mode 2, Ultra-DMA mode 2
>> Jun 14 19:33:37 tallis /netbsd: pciide0: primary channel interrupting at irq 14
>> Jun 14 19:33:37 tallis /netbsd: pciide0: secondary channel configured to compatibility mode
>> Jun 14 19:33:37 tallis /netbsd: wd1 at pciide0 channel 1 drive 0: <Maxtor 90845D4>
>> Jun 14 19:33:37 tallis /netbsd: wd1: drive supports 16-sector pio transfers, lba addressing
>> Jun 14 19:33:37 tallis /netbsd: wd1: 8063MB, 16383 cyl, 16 head, 63 sec, 512 bytes/sect x 16514064 sectors
>> Jun 14 19:33:37 tallis /netbsd: wd1: 32-bits data port
>> Jun 14 19:33:37 tallis /netbsd: wd1: drive supports PIO mode 4, DMA mode 2, Ultra-DMA mode 2
>> Jun 14 19:33:37 tallis /netbsd: pciide0: secondary channel interrupting at irq 15
>> Jun 14 19:33:37 tallis /netbsd: wd0(pciide0:0:0): using PIO mode 4, Ultra-DMA mode 2 (using DMA data transfers)
>> Jun 14 19:33:37 tallis /netbsd: cd0(pciide0:0:1): using PIO mode 4, DMA mode 2 (using DMA data transfers)
>> Jun 14 19:33:37 tallis /netbsd: wd1(pciide0:1:0): using PIO mode 4, Ultra-DMA mode 2 (using DMA data transfers)
>
>Could you try to move the CD to the secondary channel ?
>Maybe it's some kind of incompatibility between the CD and your FUJITSU
>drive ...

I've now tested the following configurations:

tallis /netbsd: wd0(pciide0:0:0): using PIO mode 4, Ultra-DMA mode 2 (using DMA data transfers)
tallis /netbsd: wd1(pciide0:1:0): using PIO mode 4, Ultra-DMA mode 2 (using DMA data transfers)
tallis /netbsd: cd0(pciide0:1:1): using PIO mode 4, Ultra-DMA mode 2 (using DMA data transfers)

Hangs system when attempting to read file from CDROM.



tallis /netbsd: wd0(pciide0:0:0): using PIO mode 4, Ultra-DMA mode 2 (using DMA data transfers)
tallis /netbsd: wd1(pciide0:1:0): using PIO mode 4, Ultra-DMA mode 2 (using DMA data transfers)
tallis /netbsd: cd0(pciide0:1:1): using PIO mode 4, DMA mode 2 (using DMA data transfers)

UDMA disabled with flags in config file - works OK.



tallis /netbsd: wd0(pciide0:0:0): using PIO mode 4, Ultra-DMA mode 2 (using DMA data transfers)
tallis /netbsd: cd0(pciide0:1:0): using PIO mode 4, Ultra-DMA mode 2 (using DMA data transfers)
(and IDE cable to wd1 was unplugged)

This was booted from an install floppy because wd1 is my 1.4 system disk, but has no MBR (and
the cabling wouldn't allow me to put both HDs on the primary channel without removing them from
the disk bays...).  After booting the install floppy, I mounted the 1.4 install CD and dd'ed
a compressed tar saveset to /dev/null.  Result: an immediate system hang with:

pciide0:1:0 lost interrupt
	type: atapi
	c_bcount: 2048
	c_skip: 0

System then remained locked solid.

Clearly, my CDROM drive is promising something which it then fails to deliver.  When I turn off
the UDMA modes in the config file it appears to work perfectly.  Maybe I'm the only person to
have met this problem?  My main concern is that someone somewhere tries to do an install from
CD, hits the same problem and concludes that NetBSD is no good.  Is it possible to have a quirk
table to restrict DMA modes on rogue drives like this?  Probably not, as the driver probe doesn't
seem to produce a vendor string.

Once again, does anyone have this model of CDROM drive working properly in UDMA mode 2?
It's an Acer Vuego CD632A (a 32x drive, bought about a year ago).



Roger

------------------------------------------------------------------------------
Roger Brooks (Systems Programmer),          |  Email: R.S.Brooks@liv.ac.uk
Computing Services Dept,                    |  Tel:   +44 151 794 4441
The University of Liverpool,                |  Fax:   +44 151 794 4442
PO Box 147, Liverpool L69 3BX, UK           | 
------------------------------------------------------------------------------