PCI: iproc: Improve core register population
authorRay Jui <ray.jui@broadcom.com>
Tue, 1 Nov 2016 00:38:30 +0000 (17:38 -0700)
committerBjorn Helgaas <bhelgaas@google.com>
Mon, 14 Nov 2016 21:41:44 +0000 (15:41 -0600)
commit06324ede76cdf895b3b0bf590775d746a61c7668
treedf661ed9946a1741aee6640acf1617dffee09612
parent1001354ca34179f3db924eb66672442a173147dc
PCI: iproc: Improve core register population

As the number of iProc PCIe core registers starts to grow and differ
between different revisions of the iProc PCIe controllers, the
current way of populating each individual unsupported register with
value 'IPROC_PCIE_REG_INVALID' with a table entry has become a bit
messy and is difficult to scale up in the future.

Improve the current driver by populating the invalid entries with code
instead of through individual table entries.  This helps to avoid a
significant number of invalid table entries when support for the next
revision of the iProc controller is added.

Signed-off-by: Ray Jui <ray.jui@broadcom.com>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Reviewed-by: Scott Branden <scott.branden@broadcom.com>
drivers/pci/host/pcie-iproc.c
drivers/pci/host/pcie-iproc.h