Re: pdc202xx.c fails to compile in 2.5.15

Petr Vandrovec
2002-05-12T22:00:05Z

On Sun, May 12, 2002 at 09:19:22PM +0200, Zlatko Calusic wrote:
> pdc202xx.x fails to compile in 2.5.15. Error messages below.
>
> pdc202xx.c:1453: unknown field `exnablebits' specified in initializer
> pdc202xx.c:1453: warning: braces around scalar initializer
> pdc202xx.c:1453: warning: (near initialization for `chipsets[3].init_dma')
> make[3]: *** [pdc202xx.o] Error 1

If you have PDC20265 like I have, you must also remove test on device class,
as 20265 reports itself as generic mass storage (class 0x0180) and not as
IDE (it is real IDE, not RAID, really).

Because of there are apparently devices on which you must check device class
(2.5.14 talks about CY82C693 and IT8172G), I'll leave proper fix on Martin,
but simple fix below work fine on my Asus A7V.
Petr Vandrovec
vandrove@vc.cvut.cz

--- drivers/ide/ide-pci.c Sun May 12 02:46:44 2002
+++ drivers/ide/ide-pci.c Fri May 10 00:25:29 2002
@@ -701,7 +701,7 @@
hpt374_device_order_fixup(dev, d);
} else if (d->vendor == PCI_VENDOR_ID_PROMISE && d->device == PCI_DEVICE_ID_PROMISE_20268R)
pdc20270_device_order_fixup(dev, d);
- else if ((dev->class >> 8) == PCI_CLASS_STORAGE_IDE) {
+ else if (1 || (dev->class >> 8) == PCI_CLASS_STORAGE_IDE) {
printk(KERN_INFO "ATA: %s (%04x:%04x) on PCI slot %s\n",
dev->name, vendor, device, dev->slot_name);
setup_pci_device(dev, d);