Messages in this thread |  | | Date | Thu, 9 Apr 2015 21:13:02 -0700 | Subject | Re: [PATCH 3/3] PCI: Set pref for mem64 resource of pcie device | From | Yinghai Lu <> |
| |
On Thu, Apr 9, 2015 at 4:31 PM, Benjamin Herrenschmidt <benh@kernel.crashing.org> wrote: >> should we make >> >> int pci_bus_alloc_resource(struct pci_bus *bus, struct resource *res, >> >> to >> >> int pci_bus_alloc_resource(struct pci_bus *bus, struct pci_dev *dev, >> struct resource *res, > > Do you need to pass bus if you have dev ?
in following path:
_pci_assign_resource only take dev, and it will go up for parent bus
while ((ret = __pci_assign_resource(bus, dev, resno, size, min_align, fit))) { if (!bus->parent || !bus->self->transparent) break; bus = bus->parent; }
and __pci_assign_resource will call pci_bus_alloc_resource.
so it is could go up several levels to use upper bus there.
|  |