PCI: Align bridge I/O windows as required by downstream devices & bridges
authorBjorn Helgaas <bhelgaas@google.com>
Mon, 5 Aug 2013 22:15:10 +0000 (16:15 -0600)
committerBjorn Helgaas <bhelgaas@google.com>
Mon, 5 Aug 2013 22:15:10 +0000 (16:15 -0600)
commit2d1d66780ecd12c9518835303f5302fc5262d49b
tree1d53810160229afde603c2e24939e852f7513986
parent11251a869e84b2a3224955fe149dd33a16805cbf
PCI: Align bridge I/O windows as required by downstream devices & bridges

An upstream bridge's I/O window must be at least as aligned as any
downstream device or bridge requires.  In particular, if the upstream
bridge supports 1K alignment but a downstream bridge requires 4K alignment,
the upstream window must also be 4K aligned.

Therefore, do not reduce the required alignment ("min_align") based on
the upstream bridge's capabilities.

Reported-by: Wei Yang <weiyang@linux.vnet.ibm.com>
Suggested-by: Yinghai Lu <yinghai@kernel.org>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
drivers/pci/setup-bus.c