Pull prarit-bus-sysdata into release branch

Tony Luck 034e5356 729c80c6

+10 -8
+10 -8
arch/ia64/sn/kernel/io_init.c
··· 323 323 struct pci_controller *controller; 324 324 struct pcibus_bussoft *prom_bussoft_ptr; 325 325 struct hubdev_info *hubdev_info; 326 - void *provider_soft; 326 + void *provider_soft = NULL; 327 327 struct sn_pcibus_provider *provider; 328 328 329 329 status = sal_get_pcibus_info((u64) segment, (u64) busnum, ··· 339 339 if (bus == NULL) { 340 340 bus = pci_scan_bus(busnum, &pci_root_ops, controller); 341 341 if (bus == NULL) 342 - return; /* error, or bus already scanned */ 342 + goto error_return; /* error, or bus already scanned */ 343 343 bus->sysdata = NULL; 344 344 } 345 345 ··· 352 352 */ 353 353 354 354 if (prom_bussoft_ptr->bs_asic_type >= PCIIO_ASIC_MAX_TYPES) 355 - return; /* unsupported asic type */ 355 + goto error_return; /* unsupported asic type */ 356 356 357 357 if (prom_bussoft_ptr->bs_asic_type == PCIIO_ASIC_TYPE_PPB) 358 358 goto error_return; /* no further fixup necessary */ 359 359 360 360 provider = sn_pci_provider[prom_bussoft_ptr->bs_asic_type]; 361 361 if (provider == NULL) 362 - return; /* no provider registerd for this asic */ 362 + goto error_return; /* no provider registerd for this asic */ 363 363 364 - provider_soft = NULL; 364 + bus->sysdata = controller; 365 365 if (provider->bus_fixup) 366 366 provider_soft = (*provider->bus_fixup) (prom_bussoft_ptr, controller); 367 367 368 - if (provider_soft == NULL) 369 - return; /* fixup failed or not applicable */ 368 + if (provider_soft == NULL) { 369 + /* fixup failed or not applicable */ 370 + bus->sysdata = NULL; 371 + goto error_return; 372 + } 370 373 371 374 /* 372 375 * Generic bus fixup goes here. Don't reference prom_bussoft_ptr 373 376 * after this point. 374 377 */ 375 378 376 - bus->sysdata = controller; 377 379 PCI_CONTROLLER(bus)->platform_data = provider_soft; 378 380 nasid = NASID_GET(SN_PCIBUS_BUSSOFT(bus)->bs_base); 379 381 cnode = nasid_to_cnodeid(nasid);