Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1 | /* |
| 2 | * This program is free software; you can redistribute it and/or modify it |
| 3 | * under the terms of the GNU General Public License as published by the |
| 4 | * Free Software Foundation; either version 2 of the License, or (at your |
| 5 | * option) any later version. |
| 6 | * |
Ralf Baechle | c539ef7 | 2012-01-11 15:37:16 +0100 | [diff] [blame^] | 7 | * Copyright (C) 2003, 04, 11 Ralf Baechle (ralf@linux-mips.org) |
| 8 | * Copyright (C) 2011 Wind River Systems, |
| 9 | * written by Ralf Baechle (ralf@linux-mips.org) |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 10 | */ |
Ralf Baechle | c539ef7 | 2012-01-11 15:37:16 +0100 | [diff] [blame^] | 11 | #include <linux/bug.h> |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 12 | #include <linux/kernel.h> |
| 13 | #include <linux/mm.h> |
| 14 | #include <linux/bootmem.h> |
Paul Gortmaker | cae39d1 | 2011-07-28 18:46:31 -0400 | [diff] [blame] | 15 | #include <linux/export.h> |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 16 | #include <linux/init.h> |
| 17 | #include <linux/types.h> |
| 18 | #include <linux/pci.h> |
| 19 | |
Ralf Baechle | c539ef7 | 2012-01-11 15:37:16 +0100 | [diff] [blame^] | 20 | #include <asm/cpu-info.h> |
| 21 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 22 | /* |
| 23 | * Indicate whether we respect the PCI setup left by the firmware. |
| 24 | * |
| 25 | * Make this long-lived so that we know when shutting down |
| 26 | * whether we probed only or not. |
| 27 | */ |
| 28 | int pci_probe_only; |
| 29 | |
| 30 | #define PCI_ASSIGN_ALL_BUSSES 1 |
| 31 | |
| 32 | unsigned int pci_probe = PCI_ASSIGN_ALL_BUSSES; |
| 33 | |
| 34 | /* |
| 35 | * The PCI controller list. |
| 36 | */ |
| 37 | |
Dmitri Vorobiev | d58eaab | 2008-06-18 10:18:20 +0300 | [diff] [blame] | 38 | static struct pci_controller *hose_head, **hose_tail = &hose_head; |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 39 | |
Ralf Baechle | 982f6ff | 2009-09-17 02:25:07 +0200 | [diff] [blame] | 40 | unsigned long PCIBIOS_MIN_IO; |
| 41 | unsigned long PCIBIOS_MIN_MEM; |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 42 | |
Aurelien Jarno | 540799e | 2008-10-14 11:45:09 +0200 | [diff] [blame] | 43 | static int pci_initialized; |
| 44 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 45 | /* |
| 46 | * We need to avoid collisions with `mirrored' VGA ports |
| 47 | * and other strange ISA hardware, so we always want the |
| 48 | * addresses to be allocated in the 0x000-0x0ff region |
| 49 | * modulo 0x400. |
| 50 | * |
| 51 | * Why? Because some silly external IO cards only decode |
| 52 | * the low 10 bits of the IO address. The 0x00-0xff region |
| 53 | * is reserved for motherboard devices that decode all 16 |
| 54 | * bits, so it's ok to allocate at, say, 0x2800-0x28ff, |
| 55 | * but we want to try to avoid allocating at 0x2900-0x2bff |
| 56 | * which might have be mirrored at 0x0100-0x03ff.. |
| 57 | */ |
Dominik Brodowski | b26b2d4 | 2010-01-01 17:40:49 +0100 | [diff] [blame] | 58 | resource_size_t |
Dominik Brodowski | 3b7a17f | 2010-01-01 17:40:50 +0100 | [diff] [blame] | 59 | pcibios_align_resource(void *data, const struct resource *res, |
Greg Kroah-Hartman | e31dd6e | 2006-06-12 17:06:02 -0700 | [diff] [blame] | 60 | resource_size_t size, resource_size_t align) |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 61 | { |
| 62 | struct pci_dev *dev = data; |
| 63 | struct pci_controller *hose = dev->sysdata; |
Greg Kroah-Hartman | e31dd6e | 2006-06-12 17:06:02 -0700 | [diff] [blame] | 64 | resource_size_t start = res->start; |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 65 | |
| 66 | if (res->flags & IORESOURCE_IO) { |
| 67 | /* Make sure we start at our min on all hoses */ |
| 68 | if (start < PCIBIOS_MIN_IO + hose->io_resource->start) |
| 69 | start = PCIBIOS_MIN_IO + hose->io_resource->start; |
| 70 | |
| 71 | /* |
| 72 | * Put everything into 0x00-0xff region modulo 0x400 |
| 73 | */ |
| 74 | if (start & 0x300) |
| 75 | start = (start + 0x3ff) & ~0x3ff; |
| 76 | } else if (res->flags & IORESOURCE_MEM) { |
| 77 | /* Make sure we start at our min on all hoses */ |
| 78 | if (start < PCIBIOS_MIN_MEM + hose->mem_resource->start) |
| 79 | start = PCIBIOS_MIN_MEM + hose->mem_resource->start; |
| 80 | } |
| 81 | |
Dominik Brodowski | b26b2d4 | 2010-01-01 17:40:49 +0100 | [diff] [blame] | 82 | return start; |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 83 | } |
| 84 | |
Aurelien Jarno | 540799e | 2008-10-14 11:45:09 +0200 | [diff] [blame] | 85 | static void __devinit pcibios_scanbus(struct pci_controller *hose) |
| 86 | { |
| 87 | static int next_busno; |
| 88 | static int need_domain_info; |
| 89 | struct pci_bus *bus; |
| 90 | |
| 91 | if (!hose->iommu) |
| 92 | PCI_DMA_BUS_IS_PHYS = 1; |
| 93 | |
| 94 | if (hose->get_busno && pci_probe_only) |
| 95 | next_busno = (*hose->get_busno)(); |
| 96 | |
| 97 | bus = pci_scan_bus(next_busno, hose->pci_ops, hose); |
| 98 | hose->bus = bus; |
| 99 | |
| 100 | need_domain_info = need_domain_info || hose->index; |
| 101 | hose->need_domain_info = need_domain_info; |
| 102 | if (bus) { |
| 103 | next_busno = bus->subordinate + 1; |
| 104 | /* Don't allow 8-bit bus number overflow inside the hose - |
| 105 | reserve some space for bridges. */ |
| 106 | if (next_busno > 224) { |
| 107 | next_busno = 0; |
| 108 | need_domain_info = 1; |
| 109 | } |
| 110 | |
| 111 | if (!pci_probe_only) { |
| 112 | pci_bus_size_bridges(bus); |
| 113 | pci_bus_assign_resources(bus); |
| 114 | pci_enable_bridges(bus); |
| 115 | } |
| 116 | } |
| 117 | } |
| 118 | |
| 119 | static DEFINE_MUTEX(pci_scan_mutex); |
| 120 | |
Ralf Baechle | 606bf78 | 2007-08-24 02:13:33 +0100 | [diff] [blame] | 121 | void __devinit register_pci_controller(struct pci_controller *hose) |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 122 | { |
Thomas Bogendoerfer | 639702b | 2007-04-08 13:28:44 +0200 | [diff] [blame] | 123 | if (request_resource(&iomem_resource, hose->mem_resource) < 0) |
| 124 | goto out; |
| 125 | if (request_resource(&ioport_resource, hose->io_resource) < 0) { |
| 126 | release_resource(hose->mem_resource); |
| 127 | goto out; |
| 128 | } |
| 129 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 130 | *hose_tail = hose; |
| 131 | hose_tail = &hose->next; |
Ralf Baechle | 140c172 | 2006-12-07 15:35:43 +0100 | [diff] [blame] | 132 | |
| 133 | /* |
Lucas De Marchi | 25985ed | 2011-03-30 22:57:33 -0300 | [diff] [blame] | 134 | * Do not panic here but later - this might happen before console init. |
Ralf Baechle | 140c172 | 2006-12-07 15:35:43 +0100 | [diff] [blame] | 135 | */ |
| 136 | if (!hose->io_map_base) { |
| 137 | printk(KERN_WARNING |
| 138 | "registering PCI controller with io_map_base unset\n"); |
| 139 | } |
Aurelien Jarno | 540799e | 2008-10-14 11:45:09 +0200 | [diff] [blame] | 140 | |
| 141 | /* |
| 142 | * Scan the bus if it is register after the PCI subsystem |
| 143 | * initialization. |
| 144 | */ |
| 145 | if (pci_initialized) { |
| 146 | mutex_lock(&pci_scan_mutex); |
| 147 | pcibios_scanbus(hose); |
| 148 | mutex_unlock(&pci_scan_mutex); |
| 149 | } |
| 150 | |
Thomas Bogendoerfer | 639702b | 2007-04-08 13:28:44 +0200 | [diff] [blame] | 151 | return; |
| 152 | |
| 153 | out: |
| 154 | printk(KERN_WARNING |
| 155 | "Skipping PCI bus scan due to resource conflict\n"); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 156 | } |
| 157 | |
Ralf Baechle | c539ef7 | 2012-01-11 15:37:16 +0100 | [diff] [blame^] | 158 | static void __init pcibios_set_cache_line_size(void) |
| 159 | { |
| 160 | struct cpuinfo_mips *c = ¤t_cpu_data; |
| 161 | unsigned int lsize; |
| 162 | |
| 163 | /* |
| 164 | * Set PCI cacheline size to that of the highest level in the |
| 165 | * cache hierarchy. |
| 166 | */ |
| 167 | lsize = c->dcache.linesz; |
| 168 | lsize = c->scache.linesz ? : lsize; |
| 169 | lsize = c->tcache.linesz ? : lsize; |
| 170 | |
| 171 | BUG_ON(!lsize); |
| 172 | |
| 173 | pci_dfl_cache_line_size = lsize >> 2; |
| 174 | |
| 175 | pr_debug("PCI: pci_cache_line_size set to %d bytes\n", lsize); |
| 176 | } |
| 177 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 178 | static int __init pcibios_init(void) |
| 179 | { |
| 180 | struct pci_controller *hose; |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 181 | |
Ralf Baechle | c539ef7 | 2012-01-11 15:37:16 +0100 | [diff] [blame^] | 182 | pcibios_set_cache_line_size(); |
| 183 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 184 | /* Scan all of the recorded PCI controllers. */ |
Aurelien Jarno | 540799e | 2008-10-14 11:45:09 +0200 | [diff] [blame] | 185 | for (hose = hose_head; hose; hose = hose->next) |
| 186 | pcibios_scanbus(hose); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 187 | |
Bjorn Helgaas | 67eed58 | 2008-12-16 21:37:10 -0700 | [diff] [blame] | 188 | pci_fixup_irqs(pci_common_swizzle, pcibios_map_irq); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 189 | |
Aurelien Jarno | 540799e | 2008-10-14 11:45:09 +0200 | [diff] [blame] | 190 | pci_initialized = 1; |
| 191 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 192 | return 0; |
| 193 | } |
| 194 | |
| 195 | subsys_initcall(pcibios_init); |
| 196 | |
| 197 | static int pcibios_enable_resources(struct pci_dev *dev, int mask) |
| 198 | { |
| 199 | u16 cmd, old_cmd; |
| 200 | int idx; |
| 201 | struct resource *r; |
| 202 | |
| 203 | pci_read_config_word(dev, PCI_COMMAND, &cmd); |
| 204 | old_cmd = cmd; |
Ralf Baechle | e5de3b4 | 2005-07-12 09:18:53 +0000 | [diff] [blame] | 205 | for (idx=0; idx < PCI_NUM_RESOURCES; idx++) { |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 206 | /* Only set up the requested stuff */ |
| 207 | if (!(mask & (1<<idx))) |
| 208 | continue; |
| 209 | |
| 210 | r = &dev->resource[idx]; |
Ralf Baechle | 986c948 | 2008-02-19 15:59:33 +0000 | [diff] [blame] | 211 | if (!(r->flags & (IORESOURCE_IO | IORESOURCE_MEM))) |
| 212 | continue; |
| 213 | if ((idx == PCI_ROM_RESOURCE) && |
| 214 | (!(r->flags & IORESOURCE_ROM_ENABLE))) |
| 215 | continue; |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 216 | if (!r->start && r->end) { |
Ralf Baechle | 40d7c1a | 2008-02-19 16:01:20 +0000 | [diff] [blame] | 217 | printk(KERN_ERR "PCI: Device %s not available " |
| 218 | "because of resource collisions\n", |
| 219 | pci_name(dev)); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 220 | return -EINVAL; |
| 221 | } |
| 222 | if (r->flags & IORESOURCE_IO) |
| 223 | cmd |= PCI_COMMAND_IO; |
| 224 | if (r->flags & IORESOURCE_MEM) |
| 225 | cmd |= PCI_COMMAND_MEMORY; |
| 226 | } |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 227 | if (cmd != old_cmd) { |
Ralf Baechle | 40d7c1a | 2008-02-19 16:01:20 +0000 | [diff] [blame] | 228 | printk("PCI: Enabling device %s (%04x -> %04x)\n", |
| 229 | pci_name(dev), old_cmd, cmd); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 230 | pci_write_config_word(dev, PCI_COMMAND, cmd); |
| 231 | } |
| 232 | return 0; |
| 233 | } |
| 234 | |
| 235 | /* |
| 236 | * If we set up a device for bus mastering, we need to check the latency |
| 237 | * timer as certain crappy BIOSes forget to set it properly. |
| 238 | */ |
Dmitri Vorobiev | 3450004 | 2008-07-15 19:57:30 +0300 | [diff] [blame] | 239 | static unsigned int pcibios_max_latency = 255; |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 240 | |
| 241 | void pcibios_set_master(struct pci_dev *dev) |
| 242 | { |
| 243 | u8 lat; |
| 244 | pci_read_config_byte(dev, PCI_LATENCY_TIMER, &lat); |
| 245 | if (lat < 16) |
| 246 | lat = (64 <= pcibios_max_latency) ? 64 : pcibios_max_latency; |
| 247 | else if (lat > pcibios_max_latency) |
| 248 | lat = pcibios_max_latency; |
| 249 | else |
| 250 | return; |
| 251 | printk(KERN_DEBUG "PCI: Setting latency timer of device %s to %d\n", |
| 252 | pci_name(dev), lat); |
| 253 | pci_write_config_byte(dev, PCI_LATENCY_TIMER, lat); |
| 254 | } |
| 255 | |
| 256 | unsigned int pcibios_assign_all_busses(void) |
| 257 | { |
| 258 | return (pci_probe & PCI_ASSIGN_ALL_BUSSES) ? 1 : 0; |
| 259 | } |
| 260 | |
| 261 | int pcibios_enable_device(struct pci_dev *dev, int mask) |
| 262 | { |
| 263 | int err; |
| 264 | |
| 265 | if ((err = pcibios_enable_resources(dev, mask)) < 0) |
| 266 | return err; |
| 267 | |
| 268 | return pcibios_plat_dev_init(dev); |
| 269 | } |
| 270 | |
Ralf Baechle | c4aa256 | 2007-08-23 14:17:14 +0100 | [diff] [blame] | 271 | static void pcibios_fixup_device_resources(struct pci_dev *dev, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 272 | struct pci_bus *bus) |
| 273 | { |
| 274 | /* Update device resources. */ |
| 275 | struct pci_controller *hose = (struct pci_controller *)bus->sysdata; |
| 276 | unsigned long offset = 0; |
| 277 | int i; |
| 278 | |
| 279 | for (i = 0; i < PCI_NUM_RESOURCES; i++) { |
| 280 | if (!dev->resource[i].start) |
| 281 | continue; |
| 282 | if (dev->resource[i].flags & IORESOURCE_IO) |
| 283 | offset = hose->io_offset; |
| 284 | else if (dev->resource[i].flags & IORESOURCE_MEM) |
| 285 | offset = hose->mem_offset; |
| 286 | |
| 287 | dev->resource[i].start += offset; |
| 288 | dev->resource[i].end += offset; |
| 289 | } |
| 290 | } |
| 291 | |
Ralf Baechle | 234fcd1 | 2008-03-08 09:56:28 +0000 | [diff] [blame] | 292 | void __devinit pcibios_fixup_bus(struct pci_bus *bus) |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 293 | { |
| 294 | /* Propagate hose info into the subordinate devices. */ |
| 295 | |
| 296 | struct pci_controller *hose = bus->sysdata; |
| 297 | struct list_head *ln; |
| 298 | struct pci_dev *dev = bus->self; |
| 299 | |
| 300 | if (!dev) { |
| 301 | bus->resource[0] = hose->io_resource; |
| 302 | bus->resource[1] = hose->mem_resource; |
| 303 | } else if (pci_probe_only && |
| 304 | (dev->class >> 8) == PCI_CLASS_BRIDGE_PCI) { |
| 305 | pci_read_bridge_bases(bus); |
| 306 | pcibios_fixup_device_resources(dev, bus); |
Ralf Baechle | 42a3b4f | 2005-09-03 15:56:17 -0700 | [diff] [blame] | 307 | } |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 308 | |
| 309 | for (ln = bus->devices.next; ln != &bus->devices; ln = ln->next) { |
Atsushi Nemoto | 8ed07a1 | 2007-07-13 01:26:52 +0900 | [diff] [blame] | 310 | dev = pci_dev_b(ln); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 311 | |
| 312 | if ((dev->class >> 8) != PCI_CLASS_BRIDGE_PCI) |
| 313 | pcibios_fixup_device_resources(dev, bus); |
| 314 | } |
| 315 | } |
| 316 | |
| 317 | void __init |
| 318 | pcibios_update_irq(struct pci_dev *dev, int irq) |
| 319 | { |
| 320 | pci_write_config_byte(dev, PCI_INTERRUPT_LINE, irq); |
| 321 | } |
| 322 | |
Ralf Baechle | c4aa256 | 2007-08-23 14:17:14 +0100 | [diff] [blame] | 323 | void pcibios_resource_to_bus(struct pci_dev *dev, struct pci_bus_region *region, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 324 | struct resource *res) |
| 325 | { |
| 326 | struct pci_controller *hose = (struct pci_controller *)dev->sysdata; |
| 327 | unsigned long offset = 0; |
| 328 | |
| 329 | if (res->flags & IORESOURCE_IO) |
| 330 | offset = hose->io_offset; |
| 331 | else if (res->flags & IORESOURCE_MEM) |
| 332 | offset = hose->mem_offset; |
| 333 | |
| 334 | region->start = res->start - offset; |
| 335 | region->end = res->end - offset; |
| 336 | } |
| 337 | |
Yoichi Yuasa | e63ea56 | 2005-09-03 15:56:20 -0700 | [diff] [blame] | 338 | void __devinit |
| 339 | pcibios_bus_to_resource(struct pci_dev *dev, struct resource *res, |
| 340 | struct pci_bus_region *region) |
| 341 | { |
| 342 | struct pci_controller *hose = (struct pci_controller *)dev->sysdata; |
| 343 | unsigned long offset = 0; |
| 344 | |
| 345 | if (res->flags & IORESOURCE_IO) |
| 346 | offset = hose->io_offset; |
| 347 | else if (res->flags & IORESOURCE_MEM) |
| 348 | offset = hose->mem_offset; |
| 349 | |
| 350 | res->start = region->start + offset; |
| 351 | res->end = region->end + offset; |
| 352 | } |
| 353 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 354 | #ifdef CONFIG_HOTPLUG |
| 355 | EXPORT_SYMBOL(pcibios_resource_to_bus); |
Yoichi Yuasa | e63ea56 | 2005-09-03 15:56:20 -0700 | [diff] [blame] | 356 | EXPORT_SYMBOL(pcibios_bus_to_resource); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 357 | EXPORT_SYMBOL(PCIBIOS_MIN_IO); |
| 358 | EXPORT_SYMBOL(PCIBIOS_MIN_MEM); |
| 359 | #endif |
| 360 | |
Ralf Baechle | 98873f5 | 2008-12-09 17:58:46 +0000 | [diff] [blame] | 361 | int pci_mmap_page_range(struct pci_dev *dev, struct vm_area_struct *vma, |
| 362 | enum pci_mmap_state mmap_state, int write_combine) |
| 363 | { |
| 364 | unsigned long prot; |
| 365 | |
| 366 | /* |
| 367 | * I/O space can be accessed via normal processor loads and stores on |
| 368 | * this platform but for now we elect not to do this and portable |
| 369 | * drivers should not do this anyway. |
| 370 | */ |
| 371 | if (mmap_state == pci_mmap_io) |
| 372 | return -EINVAL; |
| 373 | |
| 374 | /* |
| 375 | * Ignore write-combine; for now only return uncached mappings. |
| 376 | */ |
| 377 | prot = pgprot_val(vma->vm_page_prot); |
| 378 | prot = (prot & ~_CACHE_MASK) | _CACHE_UNCACHED; |
| 379 | vma->vm_page_prot = __pgprot(prot); |
| 380 | |
| 381 | return remap_pfn_range(vma, vma->vm_start, vma->vm_pgoff, |
| 382 | vma->vm_end - vma->vm_start, vma->vm_page_prot); |
| 383 | } |
| 384 | |
Atsushi Nemoto | 47a5c97 | 2008-07-24 00:25:14 +0900 | [diff] [blame] | 385 | char * (*pcibios_plat_setup)(char *str) __devinitdata; |
| 386 | |
| 387 | char *__devinit pcibios_setup(char *str) |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 388 | { |
Atsushi Nemoto | 47a5c97 | 2008-07-24 00:25:14 +0900 | [diff] [blame] | 389 | if (pcibios_plat_setup) |
| 390 | return pcibios_plat_setup(str); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 391 | return str; |
| 392 | } |