RFC x86: Convert PCI init to x86_init to simplify Moorestown support
Get series with b4
b4 am [email protected]Versions newest first
- v1 RFC Latest4 patches 1 replyIn review
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/4 | x86: Move pci init function to x86_initarch/ arch/ arch/ +12 more | +52 | 0 replies | |
| 2/4 | x86: Add pci_init_irq to x86_initarch/ arch/ arch/ +4 more | +13 | 0 replies | |
| 3/4 | x86: Add pcibios_fixup_irqs to x86_initarch/ arch/ arch/ +1 more | +8 | 0 replies | |
| 4/4 | x86: Add pci subarch init to x86_initarch/ arch/ arch/ +3 more | +13 | 1 reply |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.
Cover letter [RFC patch 0/4] x86: Convert PCI init to x86_init to simplify Moorestown support
While reviewing the Moorestown patches I noticed weird modifications to the PCI code. The main point seems to be to use pcibios_irq_init but override pci_enable_irq. This is currently not possible by overriding pci_enable_irq before that function is called as pcibios_irq_init returns when pci_enable_irq is set. Jacop proposed a function pointer in x86_init to transport that information into pcibios_irq_init but its just a another hack. I looked at the init code in pci_subsys_init which calls various platform specific setup functions which may or may not override pci_enable_irq. The most confusing thing in that series of calls is the global variable pcibios_scanned which is used to signal the functions in that call chain that the should return. The visws pci quirk does not touch pcibios_scanned so that pci_legacy_init is called to scan the bus. Pretty non obvious. :)
In order to allow a cleaner override of pci_enable_irq while still being able to call pcibios_irq_init I converted the code to use the new x86_init infrastructure.
Aside of this MRST needs another hook close to the existing #ifdef'ed OLPC pci arch init call according to the moorestown support patch in pci-2.6.git. I added a x86_init function for this as well.
The series applies on top of the x86/platform branch ingit://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip.git
It's a bit painful to puzzle the bits and pieces for MRST together. Is there some big patch which contains all of the evil hacks which are necessary to get this puppies up and running. I don't care if they are ugly but I'd really like to get the full picture of it.
Thanks,
tglx