On 2011-03-14 19.33, Anders Blomdell wrote:
> Which is due to the fact that pci_enable_device (mite.c) is called at
> mite_setup
> instead of mite_init. The bad thing with this, is that interrupt conflicts can
> only be found AFTER the driver has been started with analogy_config, which is
> often too late (since interrupt conflicts will bring down the machine).
>
> Would it be a good idea to pci_enable_device in mite_init as well, or will
> that
> break something else?
Many other kernel driver seems to call pci_enable_device from the probe
function, and this does give the card it's proper IRQ:
--- ksrc/drivers/analogy/national_instruments/mite.c.orig 2011-02-16
15:26:01.000000000 +0100
+++ ksrc/drivers/analogy/national_instruments/mite.c 2011-03-14
19:38:18.572674136 +0100
@@ -80,6 +80,7 @@
}
list_add(&mite->list, &mite_devices);
+ pci_enable_device(mite->pcidev);
return 0;
}
Regards
Anders
--
Anders Blomdell Email: [email protected]
Department of Automatic Control
Lund University Phone: +46 46 222 4625
P.O. Box 118 Fax: +46 46 138118
SE-221 00 Lund, Sweden
_______________________________________________
Xenomai-core mailing list
[email protected]
https://mail.gna.org/listinfo/xenomai-core