Linux 2.6 PCI driver module causing kernel panic on remove (rmmod)
All-
I am writing a PCI device driver for an end-user using Linux 2.6 (Gentoo 2006.0), and am having difficlty. I have a PCI device driver module that causes a kernel panic (dump below), when I rmmod the module (remove). I can build and insert (insmod) the module, detect my board and use the interrupt handler. But, when I rmmod the module, it calls the driver's .remove routine, and then I consistantly get a panic. It is a PCI device that uses shared interrupts, and I believe that this panic happens only when my PCI device shares an IRQ with another device in the system. It appears to be an interrupt-related problem from the dump (below). Any ideas what I am doing wrong or not doing on remove or in my registered interrupt routine? I have looked at dozens of drivers on my system and modeled my driver like them..... Is there a certain order I need to call my free_irq(), pci_disable_device(), unregister_chrdev(), and pci_unregister_driver() calls? I tried various different orders and even commented some out and it still panics, which makes me wonder if I am still missing something. [abbreviated dump]: ............. Code: Bad EIP value <0> KErnel panic - not syncing: Fatal Exception in interrupt ............. A thousand thanks, briek |
When I've compiled kernels I've noticed that module removal is an option. Maybe the kernel wasn't compiled with this ability.
|
stress_junkie -
Sorry, I guess I should have mentioned that this appears to only happen when one of my PCI devices is sharing an interrupt with another device in the system. I will double-check, however to be sure my kernel is supporting the module unload option.... Thanks, briek |
All times are GMT -5. The time now is 05:34 PM. |