From: Myron Stowe Date: Thu, 30 Oct 2014 17:54:43 +0000 (-0600) Subject: PCI: Shrink decoding-disabled window while sizing BARs X-Git-Tag: omap-for-v3.19/fixes-rc1~137^2~1^2~2 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f795d86aaa578501551a2d1b463eac4bbea84db2;p=pandora-kernel.git PCI: Shrink decoding-disabled window while sizing BARs __pci_read_base() disables decoding while sizing device BARs. We can't print while decoding is disabled, which leads to some rather messy exit logic. Coalesce the sizing logic to minimize the time decoding is disabled. This lets us print errors where they're detected. The refactoring also takes advantage of the symmetry of obtaining the BAR's extent (pci_size) and storing the result as the 'region' for both the 32-bit and 64-bit BARs, consolidating both cases. No functional change intended. [bhelgaas: move pci_size() up, per Thomas Petazzoni, Thierry Reding, Kevin Hilman] Signed-off-by: Myron Stowe Signed-off-by: Bjorn Helgaas CC: Matthew Wilcox --- Reading git-diff-tree failed