[PATCH v2 2/2] PCI: keystone: update to support multiple pci ports
arnd at arndb.de
Tue Sep 9 14:52:34 PDT 2014
On Tuesday 09 September 2014 17:49:19 Murali Karicheri wrote:
> Actually this is an inteded. The vendor ID is in a register indicated by
> reg offset and as per the device spec, it needs to be read and updated
> by the software. Now since multiple instances of PCI device needs to be
> read the same register, the reading happens in the probe() and same is
> unmapped after that.
> + ks_pcie->device_id = readl(reg_p) >> 16;
> + devm_iounmap(dev, reg_p);
> + devm_release_mem_region(dev, res->start, resource_size(res));
> Afetr that in ks_pcie_host_init(), it update the device_id in the RC's
> config space.
I'm not sure I understand the purpose of this. Do you mean you read
the vendor/device ID of whichever device happens to get probed first
and then program the same ID into all other devices as well?
What if the order changes between two boots? Why does the vendor/device
ID of the host bridge even matter at all?
More information about the linux-arm-kernel