hotplug remove vs. device driver close

Greg KH greg at
Fri Jun 4 02:20:20 EST 2004

On Thu, Jun 03, 2004 at 11:40:04AM +1000, Anton Blanchard wrote:
> Hi,
> > > We are hitting a situation where we are hot-plug removing a pci card
> > > before closing the device driver.  This seems to lead to kernel
> > > memory leaks if not outright crashes. I'm trying to understand what
> > > the correct solution to this is supposed to be.
> >
> > To paraphrase from the PCI Hotplug spec, "DO NOT DO THAT!"
> How do you currently guarantee this on cardbus?

We make no such guarantee.  As I stated, the Cardbus/PCMCIA handle this
quite easily, so it is pretty simple to fix up a PCI driver to also
handle this.

But the main answer is that the PCI Hotplug spec states that the OS does
NOT have to protect for this happening to regular PCI devices.


greg k-h

** Sent via the linuxppc64-dev mail list. See

More information about the Linuxppc64-dev mailing list