Lines Matching refs:r
212 struct resource *r; in pcibios_allocate_bridge_resources() local
215 r = &dev->resource[idx]; in pcibios_allocate_bridge_resources()
216 if (!r->flags) in pcibios_allocate_bridge_resources()
218 if (r->parent) /* Already allocated */ in pcibios_allocate_bridge_resources()
220 if (!r->start || pci_claim_bridge_resource(dev, idx) < 0) { in pcibios_allocate_bridge_resources()
227 r->start = r->end = 0; in pcibios_allocate_bridge_resources()
228 r->flags = 0; in pcibios_allocate_bridge_resources()
253 struct resource *r; in pcibios_allocate_dev_resources() local
265 r = &dev->resource[idx]; in pcibios_allocate_dev_resources()
266 if (r->parent) /* Already allocated */ in pcibios_allocate_dev_resources()
268 if (!r->start) /* Address not assigned at all */ in pcibios_allocate_dev_resources()
270 if (r->flags & IORESOURCE_IO) in pcibios_allocate_dev_resources()
277 idx, r, disabled, pass); in pcibios_allocate_dev_resources()
279 if (r->flags & IORESOURCE_PCI_FIXED) { in pcibios_allocate_dev_resources()
281 idx, r); in pcibios_allocate_dev_resources()
285 idx, r->start); in pcibios_allocate_dev_resources()
286 r->end -= r->start; in pcibios_allocate_dev_resources()
287 r->start = 0; in pcibios_allocate_dev_resources()
293 r = &dev->resource[PCI_ROM_RESOURCE]; in pcibios_allocate_dev_resources()
294 if (r->flags & IORESOURCE_ROM_ENABLE) { in pcibios_allocate_dev_resources()
298 dev_dbg(&dev->dev, "disabling ROM %pR\n", r); in pcibios_allocate_dev_resources()
299 r->flags &= ~IORESOURCE_ROM_ENABLE; in pcibios_allocate_dev_resources()
323 struct resource *r; in pcibios_allocate_dev_rom_resource() local
330 r = &dev->resource[PCI_ROM_RESOURCE]; in pcibios_allocate_dev_rom_resource()
331 if (!r->flags || !r->start) in pcibios_allocate_dev_rom_resource()
333 if (r->parent) /* Already allocated */ in pcibios_allocate_dev_rom_resource()
337 r->end -= r->start; in pcibios_allocate_dev_rom_resource()
338 r->start = 0; in pcibios_allocate_dev_rom_resource()