Re: i386/x86_84: disable PCI resource decode on device disable
From: Rajesh Shah
Date: Thu May 04 2006 - 16:05:47 EST
On Thu, May 04, 2006 at 05:44:21PM +0800, Antonino A. Daplas wrote:
>
> Most, if not all PCI-based framebuffer drivers call pci_disable_device()
> in their unload routine. Although it's very rare that framebuffer drivers
> are unloaded, if you do, and the the resources are also disabled, it will
> kill the VGA core of the card. You lose your text console and even
> hang the machine.
>
> >
> > Alan Cox mentioned this somewhere before in relation to video cards..
>
> Alan Cox, if I remember correctly, advises against calling pci_disable_device()
> for video drivers when they unload.
>
Yeah, that's also what some other drivers do. For example, PCI/PCIE
bridges may support capabilities (like hotplug) that are controlled
by separate drivers. These drivers don't do pci_disable_device()
when they unload, since the bridge must continue to decode even
when the other capability driver is gone.
The problem is that most PCI bridges don't have any "extra"
resources padded into the address ranges they pass down. It
would be nice to be able to reuse address space released when
a device is disabled (e.g. for future hot-add), if it's really
no longer needed.
Rajesh
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/