Page MenuHomeFreeBSD

Add a PCI bridge for the Freescale PCIe Root Complex
ClosedPublic

Authored by jhibbits on May 4 2015, 5:28 PM.
Tags
None
Referenced Files
Unknown Object (File)
May 27 2024, 10:00 AM
Unknown Object (File)
May 19 2024, 9:20 PM
Unknown Object (File)
Apr 27 2024, 8:54 AM
Unknown Object (File)
Apr 26 2024, 6:38 AM
Unknown Object (File)
Apr 26 2024, 6:31 AM
Unknown Object (File)
Apr 26 2024, 5:56 AM
Unknown Object (File)
Dec 20 2023, 12:53 AM
Unknown Object (File)
Nov 10 2023, 12:05 AM
Subscribers

Details

Reviewers
nwhitehorn
marcel
Group Reviewers
PowerPC
Summary

The Freescale PCIe Root Complex shows up as a Processor class device, PowerPC
subclass, so the generic PCI code ignores it for a bridge. This adds support
for it.

As part of this, update the Freescale PCI hostbridge driver, to allow probing
beyond the root complex, instead of only allowing "proper" PCI-PCI bridges. An
alternative, which is #if 0'd out currently, is a hack to force the secondary
bus to 'primary plus 1' if a stable PCIe link is detected. This makes the
assumption that PCIe can never have more than one bus, but it's not as elegant
as the solution I proposed. However, the solution proposed may see false
positives, and has not been tested beyond the MPC8544 in the RouterBoard RB800.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
No Lint Coverage
Unit
No Test Coverage

Event Timeline

jhibbits retitled this revision from to Add a PCI bridge for the Freescale PCIe Root Complex.
jhibbits updated this object.
jhibbits edited the test plan for this revision. (Show Details)
jhibbits added reviewers: PowerPC, marcel, nwhitehorn.

looks OK, but I'm not an expert...

sys/powerpc/mpc85xx/pci_mpc85xx.c
269

Do or Do Not. There' is no #if 0.
:)

sys/powerpc/mpc85xx/pci_mpc85xx_pcib.c
3โ€“5

Odd copyright for a new file.

sys/powerpc/mpc85xx/pci_mpc85xx.c
269

I included this as the 'very unsexy alternative' mentioned in the summary. Soliciting opinions in case someone objects to my chosen solution.

sys/powerpc/mpc85xx/pci_mpc85xx_pcib.c
3โ€“5

D'oh. That's what I get for copying the copyright+include list header.

Address copyright comment. Also, add a new function, pcib_bridge_init() to
clear the bridge config and use it in the new driver.

nwhitehorn edited edge metadata.

Nice work! I agree about the #if 0 section, though -- please remove it when you commit.

This revision is now accepted and ready to land.May 10 2015, 11:52 PM