Re: [RFC] Architecture independent pcibios?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




On Wed, Oct 09, 2013 at 03:30:35PM +0100, Bjorn Helgaas wrote:
> On Wed, Oct 9, 2013 at 4:45 AM, Liviu Dudau <Liviu.Dudau@xxxxxxx> wrote:
> 
> > Semantic question: what is the perceived difference between a pci_controller
> > and a pci_host_bridge? Are they just historical naming artifacts of the
> > same concept? (person A deciding to do a cleanup of the code and picks a
> > new name in order not to upset the old APIs)
> 
> pci_controller is a typical name for the arch-dependent PCI host
> bridge structure.  Some arches use different names, e.g.,
> pci_sys_data, pci_hba_data, pci_channel, etc.
> 
> When I added support in the PCI core for host bridge address
> translation, e.g., ACPI _TRA, I named the core structure
> pci_host_bridge.
> 
> Some of the stuff in pci_controller and similar arch-dependent
> structures could probably be moved into pci_host_bridge, given
> appropriate PCI core interfaces to supply the information (or maybe
> pcibios_*() functions the core could use to retrieve it).  But I doubt
> we could completely remove the arch-dependent structures.

How about this as a battle plan:

  - create a "generic pci_controller struct" (actual name to be picked later)
    that parses the DT for ranges and creates the relevant
    pci_host_bridge_windows, then calls pci_scan_root_bus()

  - provide some weak function definitions that arch-dependent code
    can override for the cases where the "generic pci_controller struct"
    version does not fit the bill.

Best regards,
Liviu


> 
> Bjorn
> --
> To unsubscribe from this list: send the line "unsubscribe linux-pci" in
> the body of a message to majordomo@xxxxxxxxxxxxxxx
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 

-- 
====================
| I would like to |
| fix the world,  |
| but they're not |
| giving me the   |
 \ source code!  /
  ---------------
    ¯\_(ツ)_/¯

--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Device Tree Compilter]     [Device Tree Spec]     [Linux Driver Backports]     [Video for Linux]     [Linux USB Devel]     [Linux PCI Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Yosemite Backpacking]
  Powered by Linux