Messages in this thread | | | Date | Wed, 16 Sep 2020 18:06:54 -0500 | From | Bjorn Helgaas <> | Subject | Re: [PATCH v3 04/10] PCI/RCEC: Add pcie_walk_rcec() to walk associated RCiEPs |
| |
On Tue, Sep 15, 2020 at 09:09:20AM -0700, Sean V Kelley wrote:
> Walking the bus with an RCEC as it is probed in the portdrv_pci.c can be > done with both its own bus (bitmap) and with supported associated bus > ranges. In that walk I’m able to find all the associated endpoints via both > bitmap on own bus and the bus ranges. No pci_get_slot() is needed as per > your original suggestion.
OK. That seems OK for now.
> The suggsted approach to the rcec_helper() seems to imply that we either > walk it again or have cached all the associated RCiEP. When we do the walk > above, we are merely, finding the RCiEPs and linking them to the RCEC’s > structure. There is no caching done of a list of RCiEPs per RCEC.
pcie_portdrv_init() is a device_initcall, so it should be called after we enumerate all the PCI devices (at least those present at boot). So you don't have to worry about finding an RCiEP before its associated RCEC -- we should have found them *all* by the time we get to pcie_portdrv_probe().
Bjorn
| |