
Hierarchy:
CPU
The CPU is at the top of the PCIe hierarchy.
PCIe uses a tree topology (inverted tree), meaning:
- No loops
- No mesh or arbitrary networks
- Just branches, like a family tree
This is done so that configuration software (BIOS, OS, drivers) can still work the same way as it did with PCI — it expects to find devices by walking a simple tree structure.
Root Complex (RC)
Think of the Root Complex as the big translator between the CPU and the PCIe world.
- It’s not a single chip — it may include:
- CPU interface
- Memory/DRAM controller interface
- Other host logic
- It exposes Root Ports (logical connection points for PCIe Links).
Essentially: - CPU → Root Complex → PCIe Links → Rest of the PCIe devices
📌 Key point: The Root Complex is the top of the PCIe hierarchy and the “brain” that starts configuration cycles.
Switches
- Purpose: Fan-out capability (like a network switch).
- A Switch has:
- One Upstream Port (facing toward the Root Complex)
- Multiple Downstream Ports (facing toward Endpoints)
It acts as a packet router — looks at packet headers, forwards them to the correct port.
Bridges
Bridges are translators between PCIe and other bus types:
- Forward Bridge: PCIe → legacy PCI/PCI-X bus (so you can plug old PCI cards into a new PCIe system)
- Reverse Bridge: Legacy PCI system → PCIe card (so you can use PCIe devices in an old system)
Endpoints (Devices)
Endpoints are the actual devices (network cards, GPUs, SSDs, etc.) that do useful work.
- Native PCIe Endpoint: Designed from scratch for PCIe
- Uses Memory-Mapped I/O (MMIO)
- Doesn’t rely on old PCI-specific features
- Legacy PCIe Endpoint: Old PCI/PCI-X device with a PCIe wrapper
- May use IO space or support old PCI operations (like locked transactions)
Endpoints always have only one Upstream Port (they are the leaves of the tree).
- May use IO space or support old PCI operations (like locked transactions)
🔑 Summary Table
| Component | Role | Ports |
|---|---|---|
| Root Complex | Interface between CPU & PCIe | Root Ports (Upstream start point) |
| Switch | Expands connectivity, routes packets | 1 Upstream + multiple Downstream |
| Bridge | Connects PCIe to PCI/PCI-X or another PCIe bus | 1 Upstream + 1+ Downstream |
| Endpoint | Actual device (initiator/completer of transactions) | 1 Upstream only |