aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc/kernel/pci-common.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/powerpc/kernel/pci-common.c')
-rw-r--r--arch/powerpc/kernel/pci-common.c16
1 files changed, 12 insertions, 4 deletions
diff --git a/arch/powerpc/kernel/pci-common.c b/arch/powerpc/kernel/pci-common.c
index 43fea543d68..7f94f760dd0 100644
--- a/arch/powerpc/kernel/pci-common.c
+++ b/arch/powerpc/kernel/pci-common.c
@@ -980,13 +980,14 @@ static void __devinit pcibios_fixup_bridge(struct pci_bus *bus)
980 if (i >= 3 && bus->self->transparent) 980 if (i >= 3 && bus->self->transparent)
981 continue; 981 continue;
982 982
983 /* If we are going to re-assign everything, mark the resource 983 /* If we're going to reassign everything, we can
984 * as unset and move it down to 0 984 * shrink the P2P resource to have size as being
985 * of 0 in order to save space.
985 */ 986 */
986 if (pci_has_flag(PCI_REASSIGN_ALL_RSRC)) { 987 if (pci_has_flag(PCI_REASSIGN_ALL_RSRC)) {
987 res->flags |= IORESOURCE_UNSET; 988 res->flags |= IORESOURCE_UNSET;
988 res->end -= res->start;
989 res->start = 0; 989 res->start = 0;
990 res->end = -1;
990 continue; 991 continue;
991 } 992 }
992 993
@@ -1248,7 +1249,14 @@ void pcibios_allocate_bus_resources(struct pci_bus *bus)
1248 pr_warning("PCI: Cannot allocate resource region " 1249 pr_warning("PCI: Cannot allocate resource region "
1249 "%d of PCI bridge %d, will remap\n", i, bus->number); 1250 "%d of PCI bridge %d, will remap\n", i, bus->number);
1250 clear_resource: 1251 clear_resource:
1251 res->start = res->end = 0; 1252 /* The resource might be figured out when doing
1253 * reassignment based on the resources required
1254 * by the downstream PCI devices. Here we set
1255 * the size of the resource to be 0 in order to
1256 * save more space.
1257 */
1258 res->start = 0;
1259 res->end = -1;
1252 res->flags = 0; 1260 res->flags = 0;
1253 } 1261 }
1254 1262