pci_32.c (c1f3ee120bb61045b1c0a3ead620d1d65af47130) pci_32.c (4fc665b88a79a45bae8bbf3a05563c27c7337c3d)
1/*
2 * Common pmac/prep/chrp pci routines. -- Cort
3 */
4
5#include <linux/kernel.h>
6#include <linux/pci.h>
7#include <linux/delay.h>
8#include <linux/string.h>

--- 410 unchanged lines hidden (view full) ---

419subsys_initcall(pcibios_init);
420
421void __devinit pcibios_do_bus_setup(struct pci_bus *bus)
422{
423 struct pci_controller *hose = (struct pci_controller *) bus->sysdata;
424 unsigned long io_offset;
425 struct resource *res;
426 int i;
1/*
2 * Common pmac/prep/chrp pci routines. -- Cort
3 */
4
5#include <linux/kernel.h>
6#include <linux/pci.h>
7#include <linux/delay.h>
8#include <linux/string.h>

--- 410 unchanged lines hidden (view full) ---

419subsys_initcall(pcibios_init);
420
421void __devinit pcibios_do_bus_setup(struct pci_bus *bus)
422{
423 struct pci_controller *hose = (struct pci_controller *) bus->sysdata;
424 unsigned long io_offset;
425 struct resource *res;
426 int i;
427 struct pci_dev *dev;
427
428 /* Hookup PHB resources */
429 io_offset = (unsigned long)hose->io_base_virt - isa_io_base;
430 if (bus->parent == NULL) {
431 /* This is a host bridge - fill in its resources */
432 hose->bus = bus;
433
434 bus->resource[0] = res = &hose->io_resource;

--- 17 unchanged lines hidden (view full) ---

452 "host bridge %d\n", hose->global_number);
453 res->start = hose->pci_mem_offset;
454 res->end = ~0U;
455 res->flags = IORESOURCE_MEM;
456 }
457 bus->resource[i+1] = res;
458 }
459 }
428
429 /* Hookup PHB resources */
430 io_offset = (unsigned long)hose->io_base_virt - isa_io_base;
431 if (bus->parent == NULL) {
432 /* This is a host bridge - fill in its resources */
433 hose->bus = bus;
434
435 bus->resource[0] = res = &hose->io_resource;

--- 17 unchanged lines hidden (view full) ---

453 "host bridge %d\n", hose->global_number);
454 res->start = hose->pci_mem_offset;
455 res->end = ~0U;
456 res->flags = IORESOURCE_MEM;
457 }
458 bus->resource[i+1] = res;
459 }
460 }
461
462 if (ppc_md.pci_dma_bus_setup)
463 ppc_md.pci_dma_bus_setup(bus);
464
465 list_for_each_entry(dev, &bus->devices, bus_list)
466 pcibios_setup_new_device(dev);
460}
461
462/* the next one is stolen from the alpha port... */
463void __init
464pcibios_update_irq(struct pci_dev *dev, int irq)
465{
466 pci_write_config_byte(dev, PCI_INTERRUPT_LINE, irq);
467 /* XXX FIXME - update OF device tree node interrupt property */

--- 134 unchanged lines hidden ---
467}
468
469/* the next one is stolen from the alpha port... */
470void __init
471pcibios_update_irq(struct pci_dev *dev, int irq)
472{
473 pci_write_config_byte(dev, PCI_INTERRUPT_LINE, irq);
474 /* XXX FIXME - update OF device tree node interrupt property */

--- 134 unchanged lines hidden ---