Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 12 Dec 1999 06:22:53 +0800
From:      Peter Wemm <peter@netplex.com.au>
To:        Lyndon Nerenberg <lyndon@orthanc.ab.ca>
Cc:        Adam <bsdx@looksharp.net>, freebsd-current@FreeBSD.ORG
Subject:   Re: HEADSUP: wd driver will be retired! 
Message-ID:  <19991211222254.00ADB1CD3@overcee.netplex.com.au>
In-Reply-To: Message from Lyndon Nerenberg <lyndon@orthanc.ab.ca>  of "Sat, 11 Dec 1999 14:55:46 MST." <199912112155.dBBLtkQ88825@orthanc.ab.ca> 

next in thread | previous in thread | raw e-mail | index | archive | help
Lyndon Nerenberg wrote:
> >>>>> "Adam" == Adam  <bsdx@looksharp.net> writes:
> 
>     Adam> As I understand it, cam or pre-cam or wd or ata it is simply
>     Adam> an issue of defaults.  If you plan to use disks that die or
>     Adam> become removed, simply read LINT on how to wire your disk
>     Adam> id's.
> 
> I understand. The point is: why? I had a perfectly good working system.
> Why should I have to make changes to support this new behaviour? What
> is the "benefit" of the new system? All I see is a make-work project
> for all my kernel configuration files.

The old wd driver was *solely* this way.  It was not possible to have a
dynamic system.  If you didn't have a 'device wdX at wdcY drive Z', you had
to recompile the kernel just to get to it.

The scsi system has always been dynamic with a wiring *option* right from
as far back as 2.0.  CAM didn't change this.

What is different with ata is that it has a strange hybrid of the two.  By
default (no options) it behaves like scsi.  With ATA_STATIC_ID, it does
something different - it emulates the old GENERIC layout, and it's not possible
to change that.  It used to be possible to have wd0 on wdc0 drive 1, and
wd1 on wdc0 drive 0 (ie: backwards).  It has no wiring option, but this isn't
hard to add for isa-compatable devices.

However, I point you to this example:
ata-pci0: <Intel PIIX4 ATA controller> at device 7.1 on pci0
ata-pci0: Busmastering DMA not enabled
ata-pci1: <HighPoint HPT366 ATA controller> irq 11 at device 10.0 on pci0
ata-pci1: Busmastering DMA supported
ata2 at 0x9800 irq 11 on ata-pci1
ata-pci2: <HighPoint HPT366 ATA controller> irq 11 at device 10.1 on pci0
ata-pci2: Busmastering DMA supported
ata3 at 0xa400 irq 11 on ata-pci2
ata-pci3: <HighPoint HPT366 ATA controller> irq 10 at device 11.0 on pci0
ata-pci3: Busmastering DMA supported
ata4 at 0xb000 irq 10 on ata-pci3
ata-pci4: <HighPoint HPT366 ATA controller> irq 10 at device 11.1 on pci0
ata-pci4: Busmastering DMA supported
ata5 at 0xbc00 irq 10 on ata-pci4
ata-pci5: <HighPoint HPT366 ATA controller> irq 12 at device 12.0 on pci0
ata-pci5: Busmastering DMA supported
ata6 at 0xc800 irq 12 on ata-pci5
ata-pci6: <HighPoint HPT366 ATA controller> irq 12 at device 12.1 on pci0
ata-pci6: Busmastering DMA supported
ata7 at 0xd400 irq 12 on ata-pci6
ad0: <QUANTUM FIREBALL CX10.2A/A3F.0B00> ATA-4 disk at ata2 as master
ad0: 9787MB (20044080 sectors), 19885 cyls, 16 heads, 63 S/T, 512 B/S
ad0: 16 secs/int, 1 depth queue, UDMA33
ad1: <QUANTUM FIREBALL CX6.4A/A3F.0B00> ATA-4 disk at ata3 as master
ad1: 6149MB (12594960 sectors), 13328 cyls, 15 heads, 63 S/T, 512 B/S
ad1: 16 secs/int, 1 depth queue, UDMA33
ad2: <QUANTUM FIREBALL CX6.4A/A3F.0B00> ATA-4 disk at ata4 as master
ad2: 6149MB (12594960 sectors), 13328 cyls, 15 heads, 63 S/T, 512 B/S
ad2: 16 secs/int, 1 depth queue, UDMA33
ad3: <QUANTUM FIREBALL CX6.4A/A3F.0B00> ATA-4 disk at ata5 as master
ad3: 6149MB (12594960 sectors), 13328 cyls, 15 heads, 63 S/T, 512 B/S
ad3: 16 secs/int, 1 depth queue, UDMA33
ad4: <QUANTUM FIREBALL CX6.4A/A3F.0B00> ATA-4 disk at ata6 as master
ad4: 6149MB (12594960 sectors), 13328 cyls, 15 heads, 63 S/T, 512 B/S
ad4: 16 secs/int, 1 depth queue, UDMA33
ad5: <QUANTUM FIREBALL CX6.4A/A3F.0B00> ATA-4 disk at ata7 as master
ad5: 6149MB (12594960 sectors), 13328 cyls, 15 heads, 63 S/T, 512 B/S
ad5: 16 secs/int, 1 depth queue, UDMA33

Note that ata0 and ata1 are missing and that there are no fixed or anchorable
points.  It's *impossible* to wire this down with config(8), either for
wdc or ata.  I know it isn't wired because I got burned setting it up.  I
started with a controller in the right-most slot.  It just happened that
this motherboard that's the highest pci device ID slot.  So, after setting up
and adding the other two controllers, ata2 suddenly became ata7.  ad0 became
ad4.  ATA_STATIC_ID wouldn't help because it would still have changed (ad0 would
be ad4 in static mode, and after plugging in the new controllers, ad4 would
have changed to at14.  ie: no use at all.)

wdc does not support this configuration.  It can't hook onto arbitary pci ide
devices.

With a largely dynamic bus system like PCI etc, we need a better solution.
Static wiring is not it.  What Mike Smith suggested is probably about the
best we can do and that requires devfs support.  Each disk label would have
some identifier which would be a name for the disk when attached.  ie: you
name your boot ide disk "foo" and it's device nodes become "foo", "foos1a"
or whatever.  If you move that disk from one cable to another, the device
name remains constant.  If you add a new controller to the motherboard and
the PCI bus is renumbered, you're still ok.  But.. that requires devfs to
make it work.

Cheers,
-Peter




To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-current" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?19991211222254.00ADB1CD3>