Erwan Arzur writes:
 > Recently cvsupped (as of today, and since around may 10) -current
 > kernels fail to attach my 3C905-TX nic.
<...>
 > ata-pci1: <Unknown PCI IDE controller> irq 10 at device 5.0 on pci1
 > ata-pci1: Busmastering DMA supported

<..>
 > xl0: <3Com 3c905-TX Fast Etherlink XL> irq 10 at device 8.0 on pci1
 > pci_map_int: can't allocate interrupt
 > xl0: couldn't map interrupt

The problem has nothing to do with the xl driver, actually the ata
driver is to blame.  The ata driver doesn't want to place nice & share
IRQs, and by the time the xl driver gets a chance to alloc irq10 the
ata driver has reserved it totally.  The following should fix it
(beware, its against a slightly less-than-current version of
ata-all.c; should it fail to apply, just replace the RF_SHAREABLE
arguments to bus_alloc_resource with RF_SHAREABLE | RF_ACTIVE in
ata_pciattach().

Søren's told me that he'll be fixing this in his next commit.

Drew

------------------------------------------------------------------------------
Andrew Gallatin, Sr Systems Programmer  http://www.cs.duke.edu/~gallatin
Duke University                         Email: galla...@cs.duke.edu
Department of Computer Science          Phone: (919) 660-6590



Index: /sys/dev/ata/ata-all.c
===================================================================
RCS file: /home/ncvs/src/sys/dev/ata/ata-all.c,v
retrieving revision 1.11
diff -u -b -B -r1.11 ata-all.c
--- ata-all.c   1999/04/22 08:07:44     1.11
+++ ata-all.c   1999/05/16 00:40:13
@@ -312,7 +312,8 @@
            int rid = 0;
            void *ih;
 
-           irq = bus_alloc_resource(dev, SYS_RES_IRQ, &rid, 0, ~0,1,RF_ACTIVE);
+           irq = bus_alloc_resource(dev, SYS_RES_IRQ, &rid, 0, ~0,1,
+                                     RF_SHAREABLE | RF_ACTIVE);
            if (sysctrl)
                bus_setup_intr(dev, irq, promise_intr, scp, &ih);
            else
@@ -337,7 +338,8 @@
            int rid = 0;
            void *ih;
 
-           irq = bus_alloc_resource(dev, SYS_RES_IRQ, &rid, 0, ~0,1,RF_ACTIVE);
+           irq = bus_alloc_resource(dev, SYS_RES_IRQ, &rid, 0, ~0,1,
+                                     RF_SHAREABLE | RF_ACTIVE);
            if (!sysctrl)
                bus_setup_intr(dev, irq, ataintr, scp, &ih);
        }




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

Reply via email to