diff options
Diffstat (limited to 'arch/powerpc/kernel/pci_64.c')
-rw-r--r-- | arch/powerpc/kernel/pci_64.c | 17 |
1 files changed, 6 insertions, 11 deletions
diff --git a/arch/powerpc/kernel/pci_64.c b/arch/powerpc/kernel/pci_64.c index 96edb6f8babb..9e8902fa14c7 100644 --- a/arch/powerpc/kernel/pci_64.c +++ b/arch/powerpc/kernel/pci_64.c | |||
@@ -43,16 +43,6 @@ unsigned long pci_probe_only = 1; | |||
43 | unsigned long pci_io_base = ISA_IO_BASE; | 43 | unsigned long pci_io_base = ISA_IO_BASE; |
44 | EXPORT_SYMBOL(pci_io_base); | 44 | EXPORT_SYMBOL(pci_io_base); |
45 | 45 | ||
46 | static void fixup_broken_pcnet32(struct pci_dev* dev) | ||
47 | { | ||
48 | if ((dev->class>>8 == PCI_CLASS_NETWORK_ETHERNET)) { | ||
49 | dev->vendor = PCI_VENDOR_ID_AMD; | ||
50 | pci_write_config_word(dev, PCI_VENDOR_ID, PCI_VENDOR_ID_AMD); | ||
51 | } | ||
52 | } | ||
53 | DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_TRIDENT, PCI_ANY_ID, fixup_broken_pcnet32); | ||
54 | |||
55 | |||
56 | static u32 get_int_prop(struct device_node *np, const char *name, u32 def) | 46 | static u32 get_int_prop(struct device_node *np, const char *name, u32 def) |
57 | { | 47 | { |
58 | const u32 *prop; | 48 | const u32 *prop; |
@@ -430,6 +420,9 @@ int pcibios_unmap_io_space(struct pci_bus *bus) | |||
430 | * so flushing the hash table is the only sane way to make sure | 420 | * so flushing the hash table is the only sane way to make sure |
431 | * that no hash entries are covering that removed bridge area | 421 | * that no hash entries are covering that removed bridge area |
432 | * while still allowing other busses overlapping those pages | 422 | * while still allowing other busses overlapping those pages |
423 | * | ||
424 | * Note: If we ever support P2P hotplug on Book3E, we'll have | ||
425 | * to do an appropriate TLB flush here too | ||
433 | */ | 426 | */ |
434 | if (bus->self) { | 427 | if (bus->self) { |
435 | struct resource *res = bus->resource[0]; | 428 | struct resource *res = bus->resource[0]; |
@@ -437,8 +430,10 @@ int pcibios_unmap_io_space(struct pci_bus *bus) | |||
437 | pr_debug("IO unmapping for PCI-PCI bridge %s\n", | 430 | pr_debug("IO unmapping for PCI-PCI bridge %s\n", |
438 | pci_name(bus->self)); | 431 | pci_name(bus->self)); |
439 | 432 | ||
433 | #ifdef CONFIG_PPC_STD_MMU_64 | ||
440 | __flush_hash_table_range(&init_mm, res->start + _IO_BASE, | 434 | __flush_hash_table_range(&init_mm, res->start + _IO_BASE, |
441 | res->end + _IO_BASE + 1); | 435 | res->end + _IO_BASE + 1); |
436 | #endif | ||
442 | return 0; | 437 | return 0; |
443 | } | 438 | } |
444 | 439 | ||
@@ -511,7 +506,7 @@ int __devinit pcibios_map_io_space(struct pci_bus *bus) | |||
511 | pr_debug("IO mapping for PHB %s\n", hose->dn->full_name); | 506 | pr_debug("IO mapping for PHB %s\n", hose->dn->full_name); |
512 | pr_debug(" phys=0x%016llx, virt=0x%p (alloc=0x%p)\n", | 507 | pr_debug(" phys=0x%016llx, virt=0x%p (alloc=0x%p)\n", |
513 | hose->io_base_phys, hose->io_base_virt, hose->io_base_alloc); | 508 | hose->io_base_phys, hose->io_base_virt, hose->io_base_alloc); |
514 | pr_debug(" size=0x%016lx (alloc=0x%016lx)\n", | 509 | pr_debug(" size=0x%016llx (alloc=0x%016lx)\n", |
515 | hose->pci_io_size, size_page); | 510 | hose->pci_io_size, size_page); |
516 | 511 | ||
517 | /* Establish the mapping */ | 512 | /* Establish the mapping */ |