Subject: Re: Problem with PCI bus rescan on 460EX

From: Felix Radensky <[email-masked]>
Date: Thu, 11 Mar 2010 23:41:09 +0200

Hi Ben,

Benjamin Herrenschmidt wrote:
> Yes, we need to do a resource allocation pass, setup DMA, etc... and
> that is not done in that manual rescan case I suppose. I have to look.
>
> Part of the problem is that there is no "proper" hooks in the generic
> PCI code that I know of for that, but I'll have to double check the
> code, things might have changed.
>
> For boot time, we do this after we scan busses and before we add the
> devices to sysfs. For hotplug, our hotplug drivers do something similar.
> But that "rescan" sysfs hook seems to go directly into drivers/pci
> causing a rescan but without a change to re-allocate resources etc...
>
> You may be better off implementing a minimum hotplug driver I suppose...
>
> Cheers,
> Ben.
>
>   
I'm fine with creating a minimal hotplug driver. The device I'm dealing with
partially implements Compact PCI hotplug. It generates ENUM# interrupt, but
Hotswap Control register layout does not completely follow the standard.

Should I use drivers/pci/hotplug/cpci_hotplug_core.c as a base, or do 
you have
something more simple in mind ?

Thanks a lot.

Felix.