diff options
author | Jens Axboe <jens.axboe@oracle.com> | 2009-05-22 14:25:34 -0400 |
---|---|---|
committer | Jens Axboe <jens.axboe@oracle.com> | 2009-05-22 14:25:34 -0400 |
commit | e4b636366c00738b9609cda307014d71b1225b7f (patch) | |
tree | 760b67b3624eda62e943e48ce93635c30a5b47bf /drivers/pci | |
parent | b9ed7252d219c1c663944bf03846eabb515dbe75 (diff) | |
parent | 279e677faa775ad16e75c32e1bf4a37f8158bc61 (diff) |
Merge branch 'master' into for-2.6.31
Conflicts:
drivers/block/hd.c
drivers/block/mg_disk.c
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
Diffstat (limited to 'drivers/pci')
-rw-r--r-- | drivers/pci/access.c | 4 | ||||
-rw-r--r-- | drivers/pci/htirq.c | 1 | ||||
-rw-r--r-- | drivers/pci/intel-iommu.c | 13 | ||||
-rw-r--r-- | drivers/pci/msi.c | 8 | ||||
-rw-r--r-- | drivers/pci/pci-sysfs.c | 12 | ||||
-rw-r--r-- | drivers/pci/pci.c | 70 | ||||
-rw-r--r-- | drivers/pci/pcie/aer/aerdrv.h | 3 | ||||
-rw-r--r-- | drivers/pci/pcie/portdrv_pci.c | 2 | ||||
-rw-r--r-- | drivers/pci/probe.c | 6 | ||||
-rw-r--r-- | drivers/pci/quirks.c | 1 | ||||
-rw-r--r-- | drivers/pci/setup-bus.c | 6 | ||||
-rw-r--r-- | drivers/pci/slot.c | 4 |
12 files changed, 93 insertions, 37 deletions
diff --git a/drivers/pci/access.c b/drivers/pci/access.c index 64dd7df90e62..0f3706512686 100644 --- a/drivers/pci/access.c +++ b/drivers/pci/access.c | |||
@@ -87,8 +87,8 @@ EXPORT_SYMBOL(pci_read_vpd); | |||
87 | * pci_write_vpd - Write entry to Vital Product Data | 87 | * pci_write_vpd - Write entry to Vital Product Data |
88 | * @dev: pci device struct | 88 | * @dev: pci device struct |
89 | * @pos: offset in vpd space | 89 | * @pos: offset in vpd space |
90 | * @count: number of bytes to read | 90 | * @count: number of bytes to write |
91 | * @val: value to write | 91 | * @buf: buffer containing write data |
92 | * | 92 | * |
93 | */ | 93 | */ |
94 | ssize_t pci_write_vpd(struct pci_dev *dev, loff_t pos, size_t count, const void *buf) | 94 | ssize_t pci_write_vpd(struct pci_dev *dev, loff_t pos, size_t count, const void *buf) |
diff --git a/drivers/pci/htirq.c b/drivers/pci/htirq.c index bf7d6ce9bbb3..6808d8333ecc 100644 --- a/drivers/pci/htirq.c +++ b/drivers/pci/htirq.c | |||
@@ -158,6 +158,7 @@ int ht_create_irq(struct pci_dev *dev, int idx) | |||
158 | 158 | ||
159 | /** | 159 | /** |
160 | * ht_destroy_irq - destroy an irq created with ht_create_irq | 160 | * ht_destroy_irq - destroy an irq created with ht_create_irq |
161 | * @irq: irq to be destroyed | ||
161 | * | 162 | * |
162 | * This reverses ht_create_irq removing the specified irq from | 163 | * This reverses ht_create_irq removing the specified irq from |
163 | * existence. The irq should be free before this happens. | 164 | * existence. The irq should be free before this happens. |
diff --git a/drivers/pci/intel-iommu.c b/drivers/pci/intel-iommu.c index 001b328adf80..a563fbe559d0 100644 --- a/drivers/pci/intel-iommu.c +++ b/drivers/pci/intel-iommu.c | |||
@@ -59,6 +59,10 @@ | |||
59 | #define DMA_32BIT_PFN IOVA_PFN(DMA_BIT_MASK(32)) | 59 | #define DMA_32BIT_PFN IOVA_PFN(DMA_BIT_MASK(32)) |
60 | #define DMA_64BIT_PFN IOVA_PFN(DMA_BIT_MASK(64)) | 60 | #define DMA_64BIT_PFN IOVA_PFN(DMA_BIT_MASK(64)) |
61 | 61 | ||
62 | #ifndef PHYSICAL_PAGE_MASK | ||
63 | #define PHYSICAL_PAGE_MASK PAGE_MASK | ||
64 | #endif | ||
65 | |||
62 | /* global iommu list, set NULL for ignored DMAR units */ | 66 | /* global iommu list, set NULL for ignored DMAR units */ |
63 | static struct intel_iommu **g_iommus; | 67 | static struct intel_iommu **g_iommus; |
64 | 68 | ||
@@ -1216,7 +1220,7 @@ static void dmar_init_reserved_ranges(void) | |||
1216 | if (!r->flags || !(r->flags & IORESOURCE_MEM)) | 1220 | if (!r->flags || !(r->flags & IORESOURCE_MEM)) |
1217 | continue; | 1221 | continue; |
1218 | addr = r->start; | 1222 | addr = r->start; |
1219 | addr &= PAGE_MASK; | 1223 | addr &= PHYSICAL_PAGE_MASK; |
1220 | size = r->end - addr; | 1224 | size = r->end - addr; |
1221 | size = PAGE_ALIGN(size); | 1225 | size = PAGE_ALIGN(size); |
1222 | iova = reserve_iova(&reserved_iova_list, IOVA_PFN(addr), | 1226 | iova = reserve_iova(&reserved_iova_list, IOVA_PFN(addr), |
@@ -2173,7 +2177,8 @@ static dma_addr_t __intel_map_single(struct device *hwdev, phys_addr_t paddr, | |||
2173 | * is not a big problem | 2177 | * is not a big problem |
2174 | */ | 2178 | */ |
2175 | ret = domain_page_mapping(domain, start_paddr, | 2179 | ret = domain_page_mapping(domain, start_paddr, |
2176 | ((u64)paddr) & PAGE_MASK, size, prot); | 2180 | ((u64)paddr) & PHYSICAL_PAGE_MASK, |
2181 | size, prot); | ||
2177 | if (ret) | 2182 | if (ret) |
2178 | goto error; | 2183 | goto error; |
2179 | 2184 | ||
@@ -2463,8 +2468,8 @@ static int intel_map_sg(struct device *hwdev, struct scatterlist *sglist, int ne | |||
2463 | addr = page_to_phys(sg_page(sg)) + sg->offset; | 2468 | addr = page_to_phys(sg_page(sg)) + sg->offset; |
2464 | size = aligned_size((u64)addr, sg->length); | 2469 | size = aligned_size((u64)addr, sg->length); |
2465 | ret = domain_page_mapping(domain, start_addr + offset, | 2470 | ret = domain_page_mapping(domain, start_addr + offset, |
2466 | ((u64)addr) & PAGE_MASK, | 2471 | ((u64)addr) & PHYSICAL_PAGE_MASK, |
2467 | size, prot); | 2472 | size, prot); |
2468 | if (ret) { | 2473 | if (ret) { |
2469 | /* clear the page */ | 2474 | /* clear the page */ |
2470 | dma_pte_clear_range(domain, start_addr, | 2475 | dma_pte_clear_range(domain, start_addr, |
diff --git a/drivers/pci/msi.c b/drivers/pci/msi.c index 6f2e6295e773..362773247fbf 100644 --- a/drivers/pci/msi.c +++ b/drivers/pci/msi.c | |||
@@ -455,8 +455,6 @@ static int msix_capability_init(struct pci_dev *dev, | |||
455 | entry->msi_attrib.default_irq = dev->irq; | 455 | entry->msi_attrib.default_irq = dev->irq; |
456 | entry->msi_attrib.pos = pos; | 456 | entry->msi_attrib.pos = pos; |
457 | entry->mask_base = base; | 457 | entry->mask_base = base; |
458 | entry->masked = readl(base + j * PCI_MSIX_ENTRY_SIZE + | ||
459 | PCI_MSIX_ENTRY_VECTOR_CTRL_OFFSET); | ||
460 | msix_mask_irq(entry, 1); | 458 | msix_mask_irq(entry, 1); |
461 | 459 | ||
462 | list_add_tail(&entry->list, &dev->msi_list); | 460 | list_add_tail(&entry->list, &dev->msi_list); |
@@ -493,6 +491,12 @@ static int msix_capability_init(struct pci_dev *dev, | |||
493 | msix_set_enable(dev, 1); | 491 | msix_set_enable(dev, 1); |
494 | dev->msix_enabled = 1; | 492 | dev->msix_enabled = 1; |
495 | 493 | ||
494 | list_for_each_entry(entry, &dev->msi_list, list) { | ||
495 | int vector = entry->msi_attrib.entry_nr; | ||
496 | entry->masked = readl(base + vector * PCI_MSIX_ENTRY_SIZE + | ||
497 | PCI_MSIX_ENTRY_VECTOR_CTRL_OFFSET); | ||
498 | } | ||
499 | |||
496 | return 0; | 500 | return 0; |
497 | } | 501 | } |
498 | 502 | ||
diff --git a/drivers/pci/pci-sysfs.c b/drivers/pci/pci-sysfs.c index a7eb1b46a5a8..85ebd02a64a7 100644 --- a/drivers/pci/pci-sysfs.c +++ b/drivers/pci/pci-sysfs.c | |||
@@ -492,6 +492,7 @@ write_vpd_attr(struct kobject *kobj, struct bin_attribute *bin_attr, | |||
492 | /** | 492 | /** |
493 | * pci_read_legacy_io - read byte(s) from legacy I/O port space | 493 | * pci_read_legacy_io - read byte(s) from legacy I/O port space |
494 | * @kobj: kobject corresponding to file to read from | 494 | * @kobj: kobject corresponding to file to read from |
495 | * @bin_attr: struct bin_attribute for this file | ||
495 | * @buf: buffer to store results | 496 | * @buf: buffer to store results |
496 | * @off: offset into legacy I/O port space | 497 | * @off: offset into legacy I/O port space |
497 | * @count: number of bytes to read | 498 | * @count: number of bytes to read |
@@ -517,6 +518,7 @@ pci_read_legacy_io(struct kobject *kobj, struct bin_attribute *bin_attr, | |||
517 | /** | 518 | /** |
518 | * pci_write_legacy_io - write byte(s) to legacy I/O port space | 519 | * pci_write_legacy_io - write byte(s) to legacy I/O port space |
519 | * @kobj: kobject corresponding to file to read from | 520 | * @kobj: kobject corresponding to file to read from |
521 | * @bin_attr: struct bin_attribute for this file | ||
520 | * @buf: buffer containing value to be written | 522 | * @buf: buffer containing value to be written |
521 | * @off: offset into legacy I/O port space | 523 | * @off: offset into legacy I/O port space |
522 | * @count: number of bytes to write | 524 | * @count: number of bytes to write |
@@ -733,9 +735,9 @@ pci_mmap_resource_wc(struct kobject *kobj, struct bin_attribute *attr, | |||
733 | 735 | ||
734 | /** | 736 | /** |
735 | * pci_remove_resource_files - cleanup resource files | 737 | * pci_remove_resource_files - cleanup resource files |
736 | * @dev: dev to cleanup | 738 | * @pdev: dev to cleanup |
737 | * | 739 | * |
738 | * If we created resource files for @dev, remove them from sysfs and | 740 | * If we created resource files for @pdev, remove them from sysfs and |
739 | * free their resources. | 741 | * free their resources. |
740 | */ | 742 | */ |
741 | static void | 743 | static void |
@@ -793,9 +795,9 @@ static int pci_create_attr(struct pci_dev *pdev, int num, int write_combine) | |||
793 | 795 | ||
794 | /** | 796 | /** |
795 | * pci_create_resource_files - create resource files in sysfs for @dev | 797 | * pci_create_resource_files - create resource files in sysfs for @dev |
796 | * @dev: dev in question | 798 | * @pdev: dev in question |
797 | * | 799 | * |
798 | * Walk the resources in @dev creating files for each resource available. | 800 | * Walk the resources in @pdev creating files for each resource available. |
799 | */ | 801 | */ |
800 | static int pci_create_resource_files(struct pci_dev *pdev) | 802 | static int pci_create_resource_files(struct pci_dev *pdev) |
801 | { | 803 | { |
@@ -829,6 +831,7 @@ void __weak pci_remove_resource_files(struct pci_dev *dev) { return; } | |||
829 | /** | 831 | /** |
830 | * pci_write_rom - used to enable access to the PCI ROM display | 832 | * pci_write_rom - used to enable access to the PCI ROM display |
831 | * @kobj: kernel object handle | 833 | * @kobj: kernel object handle |
834 | * @bin_attr: struct bin_attribute for this file | ||
832 | * @buf: user input | 835 | * @buf: user input |
833 | * @off: file offset | 836 | * @off: file offset |
834 | * @count: number of byte in input | 837 | * @count: number of byte in input |
@@ -852,6 +855,7 @@ pci_write_rom(struct kobject *kobj, struct bin_attribute *bin_attr, | |||
852 | /** | 855 | /** |
853 | * pci_read_rom - read a PCI ROM | 856 | * pci_read_rom - read a PCI ROM |
854 | * @kobj: kernel object handle | 857 | * @kobj: kernel object handle |
858 | * @bin_attr: struct bin_attribute for this file | ||
855 | * @buf: where to put the data we read from the ROM | 859 | * @buf: where to put the data we read from the ROM |
856 | * @off: file offset | 860 | * @off: file offset |
857 | * @count: number of bytes to read | 861 | * @count: number of bytes to read |
diff --git a/drivers/pci/pci.c b/drivers/pci/pci.c index 16fd0d4c3166..34bf0fdf5047 100644 --- a/drivers/pci/pci.c +++ b/drivers/pci/pci.c | |||
@@ -681,11 +681,34 @@ EXPORT_SYMBOL(pci_choose_state); | |||
681 | 681 | ||
682 | #define PCI_EXP_SAVE_REGS 7 | 682 | #define PCI_EXP_SAVE_REGS 7 |
683 | 683 | ||
684 | #define pcie_cap_has_devctl(type, flags) 1 | ||
685 | #define pcie_cap_has_lnkctl(type, flags) \ | ||
686 | ((flags & PCI_EXP_FLAGS_VERS) > 1 || \ | ||
687 | (type == PCI_EXP_TYPE_ROOT_PORT || \ | ||
688 | type == PCI_EXP_TYPE_ENDPOINT || \ | ||
689 | type == PCI_EXP_TYPE_LEG_END)) | ||
690 | #define pcie_cap_has_sltctl(type, flags) \ | ||
691 | ((flags & PCI_EXP_FLAGS_VERS) > 1 || \ | ||
692 | ((type == PCI_EXP_TYPE_ROOT_PORT) || \ | ||
693 | (type == PCI_EXP_TYPE_DOWNSTREAM && \ | ||
694 | (flags & PCI_EXP_FLAGS_SLOT)))) | ||
695 | #define pcie_cap_has_rtctl(type, flags) \ | ||
696 | ((flags & PCI_EXP_FLAGS_VERS) > 1 || \ | ||
697 | (type == PCI_EXP_TYPE_ROOT_PORT || \ | ||
698 | type == PCI_EXP_TYPE_RC_EC)) | ||
699 | #define pcie_cap_has_devctl2(type, flags) \ | ||
700 | ((flags & PCI_EXP_FLAGS_VERS) > 1) | ||
701 | #define pcie_cap_has_lnkctl2(type, flags) \ | ||
702 | ((flags & PCI_EXP_FLAGS_VERS) > 1) | ||
703 | #define pcie_cap_has_sltctl2(type, flags) \ | ||
704 | ((flags & PCI_EXP_FLAGS_VERS) > 1) | ||
705 | |||
684 | static int pci_save_pcie_state(struct pci_dev *dev) | 706 | static int pci_save_pcie_state(struct pci_dev *dev) |
685 | { | 707 | { |
686 | int pos, i = 0; | 708 | int pos, i = 0; |
687 | struct pci_cap_saved_state *save_state; | 709 | struct pci_cap_saved_state *save_state; |
688 | u16 *cap; | 710 | u16 *cap; |
711 | u16 flags; | ||
689 | 712 | ||
690 | pos = pci_find_capability(dev, PCI_CAP_ID_EXP); | 713 | pos = pci_find_capability(dev, PCI_CAP_ID_EXP); |
691 | if (pos <= 0) | 714 | if (pos <= 0) |
@@ -698,13 +721,22 @@ static int pci_save_pcie_state(struct pci_dev *dev) | |||
698 | } | 721 | } |
699 | cap = (u16 *)&save_state->data[0]; | 722 | cap = (u16 *)&save_state->data[0]; |
700 | 723 | ||
701 | pci_read_config_word(dev, pos + PCI_EXP_DEVCTL, &cap[i++]); | 724 | pci_read_config_word(dev, pos + PCI_EXP_FLAGS, &flags); |
702 | pci_read_config_word(dev, pos + PCI_EXP_LNKCTL, &cap[i++]); | 725 | |
703 | pci_read_config_word(dev, pos + PCI_EXP_SLTCTL, &cap[i++]); | 726 | if (pcie_cap_has_devctl(dev->pcie_type, flags)) |
704 | pci_read_config_word(dev, pos + PCI_EXP_RTCTL, &cap[i++]); | 727 | pci_read_config_word(dev, pos + PCI_EXP_DEVCTL, &cap[i++]); |
705 | pci_read_config_word(dev, pos + PCI_EXP_DEVCTL2, &cap[i++]); | 728 | if (pcie_cap_has_lnkctl(dev->pcie_type, flags)) |
706 | pci_read_config_word(dev, pos + PCI_EXP_LNKCTL2, &cap[i++]); | 729 | pci_read_config_word(dev, pos + PCI_EXP_LNKCTL, &cap[i++]); |
707 | pci_read_config_word(dev, pos + PCI_EXP_SLTCTL2, &cap[i++]); | 730 | if (pcie_cap_has_sltctl(dev->pcie_type, flags)) |
731 | pci_read_config_word(dev, pos + PCI_EXP_SLTCTL, &cap[i++]); | ||
732 | if (pcie_cap_has_rtctl(dev->pcie_type, flags)) | ||
733 | pci_read_config_word(dev, pos + PCI_EXP_RTCTL, &cap[i++]); | ||
734 | if (pcie_cap_has_devctl2(dev->pcie_type, flags)) | ||
735 | pci_read_config_word(dev, pos + PCI_EXP_DEVCTL2, &cap[i++]); | ||
736 | if (pcie_cap_has_lnkctl2(dev->pcie_type, flags)) | ||
737 | pci_read_config_word(dev, pos + PCI_EXP_LNKCTL2, &cap[i++]); | ||
738 | if (pcie_cap_has_sltctl2(dev->pcie_type, flags)) | ||
739 | pci_read_config_word(dev, pos + PCI_EXP_SLTCTL2, &cap[i++]); | ||
708 | 740 | ||
709 | return 0; | 741 | return 0; |
710 | } | 742 | } |
@@ -714,6 +746,7 @@ static void pci_restore_pcie_state(struct pci_dev *dev) | |||
714 | int i = 0, pos; | 746 | int i = 0, pos; |
715 | struct pci_cap_saved_state *save_state; | 747 | struct pci_cap_saved_state *save_state; |
716 | u16 *cap; | 748 | u16 *cap; |
749 | u16 flags; | ||
717 | 750 | ||
718 | save_state = pci_find_saved_cap(dev, PCI_CAP_ID_EXP); | 751 | save_state = pci_find_saved_cap(dev, PCI_CAP_ID_EXP); |
719 | pos = pci_find_capability(dev, PCI_CAP_ID_EXP); | 752 | pos = pci_find_capability(dev, PCI_CAP_ID_EXP); |
@@ -721,13 +754,22 @@ static void pci_restore_pcie_state(struct pci_dev *dev) | |||
721 | return; | 754 | return; |
722 | cap = (u16 *)&save_state->data[0]; | 755 | cap = (u16 *)&save_state->data[0]; |
723 | 756 | ||
724 | pci_write_config_word(dev, pos + PCI_EXP_DEVCTL, cap[i++]); | 757 | pci_read_config_word(dev, pos + PCI_EXP_FLAGS, &flags); |
725 | pci_write_config_word(dev, pos + PCI_EXP_LNKCTL, cap[i++]); | 758 | |
726 | pci_write_config_word(dev, pos + PCI_EXP_SLTCTL, cap[i++]); | 759 | if (pcie_cap_has_devctl(dev->pcie_type, flags)) |
727 | pci_write_config_word(dev, pos + PCI_EXP_RTCTL, cap[i++]); | 760 | pci_write_config_word(dev, pos + PCI_EXP_DEVCTL, cap[i++]); |
728 | pci_write_config_word(dev, pos + PCI_EXP_DEVCTL2, cap[i++]); | 761 | if (pcie_cap_has_lnkctl(dev->pcie_type, flags)) |
729 | pci_write_config_word(dev, pos + PCI_EXP_LNKCTL2, cap[i++]); | 762 | pci_write_config_word(dev, pos + PCI_EXP_LNKCTL, cap[i++]); |
730 | pci_write_config_word(dev, pos + PCI_EXP_SLTCTL2, cap[i++]); | 763 | if (pcie_cap_has_sltctl(dev->pcie_type, flags)) |
764 | pci_write_config_word(dev, pos + PCI_EXP_SLTCTL, cap[i++]); | ||
765 | if (pcie_cap_has_rtctl(dev->pcie_type, flags)) | ||
766 | pci_write_config_word(dev, pos + PCI_EXP_RTCTL, cap[i++]); | ||
767 | if (pcie_cap_has_devctl2(dev->pcie_type, flags)) | ||
768 | pci_write_config_word(dev, pos + PCI_EXP_DEVCTL2, cap[i++]); | ||
769 | if (pcie_cap_has_lnkctl2(dev->pcie_type, flags)) | ||
770 | pci_write_config_word(dev, pos + PCI_EXP_LNKCTL2, cap[i++]); | ||
771 | if (pcie_cap_has_sltctl2(dev->pcie_type, flags)) | ||
772 | pci_write_config_word(dev, pos + PCI_EXP_SLTCTL2, cap[i++]); | ||
731 | } | 773 | } |
732 | 774 | ||
733 | 775 | ||
diff --git a/drivers/pci/pcie/aer/aerdrv.h b/drivers/pci/pcie/aer/aerdrv.h index c7ad68b6c6d6..aa14482a4779 100644 --- a/drivers/pci/pcie/aer/aerdrv.h +++ b/drivers/pci/pcie/aer/aerdrv.h | |||
@@ -95,6 +95,9 @@ struct aer_broadcast_data { | |||
95 | static inline pci_ers_result_t merge_result(enum pci_ers_result orig, | 95 | static inline pci_ers_result_t merge_result(enum pci_ers_result orig, |
96 | enum pci_ers_result new) | 96 | enum pci_ers_result new) |
97 | { | 97 | { |
98 | if (new == PCI_ERS_RESULT_NONE) | ||
99 | return orig; | ||
100 | |||
98 | switch (orig) { | 101 | switch (orig) { |
99 | case PCI_ERS_RESULT_CAN_RECOVER: | 102 | case PCI_ERS_RESULT_CAN_RECOVER: |
100 | case PCI_ERS_RESULT_RECOVERED: | 103 | case PCI_ERS_RESULT_RECOVERED: |
diff --git a/drivers/pci/pcie/portdrv_pci.c b/drivers/pci/pcie/portdrv_pci.c index b924e2463f85..091ce70051e0 100644 --- a/drivers/pci/pcie/portdrv_pci.c +++ b/drivers/pci/pcie/portdrv_pci.c | |||
@@ -200,7 +200,7 @@ static int slot_reset_iter(struct device *device, void *data) | |||
200 | 200 | ||
201 | static pci_ers_result_t pcie_portdrv_slot_reset(struct pci_dev *dev) | 201 | static pci_ers_result_t pcie_portdrv_slot_reset(struct pci_dev *dev) |
202 | { | 202 | { |
203 | pci_ers_result_t status = PCI_ERS_RESULT_NONE; | 203 | pci_ers_result_t status = PCI_ERS_RESULT_RECOVERED; |
204 | int retval; | 204 | int retval; |
205 | 205 | ||
206 | /* If fatal, restore cfg space for possible link reset at upstream */ | 206 | /* If fatal, restore cfg space for possible link reset at upstream */ |
diff --git a/drivers/pci/probe.c b/drivers/pci/probe.c index 8eb50dffb78a..e3c3e081b834 100644 --- a/drivers/pci/probe.c +++ b/drivers/pci/probe.c | |||
@@ -1118,10 +1118,6 @@ unsigned int __devinit pci_scan_child_bus(struct pci_bus *bus) | |||
1118 | return max; | 1118 | return max; |
1119 | } | 1119 | } |
1120 | 1120 | ||
1121 | void __attribute__((weak)) set_pci_bus_resources_arch_default(struct pci_bus *b) | ||
1122 | { | ||
1123 | } | ||
1124 | |||
1125 | struct pci_bus * pci_create_bus(struct device *parent, | 1121 | struct pci_bus * pci_create_bus(struct device *parent, |
1126 | int bus, struct pci_ops *ops, void *sysdata) | 1122 | int bus, struct pci_ops *ops, void *sysdata) |
1127 | { | 1123 | { |
@@ -1180,8 +1176,6 @@ struct pci_bus * pci_create_bus(struct device *parent, | |||
1180 | b->resource[0] = &ioport_resource; | 1176 | b->resource[0] = &ioport_resource; |
1181 | b->resource[1] = &iomem_resource; | 1177 | b->resource[1] = &iomem_resource; |
1182 | 1178 | ||
1183 | set_pci_bus_resources_arch_default(b); | ||
1184 | |||
1185 | return b; | 1179 | return b; |
1186 | 1180 | ||
1187 | dev_create_file_err: | 1181 | dev_create_file_err: |
diff --git a/drivers/pci/quirks.c b/drivers/pci/quirks.c index 0254741bece0..3067673d54f6 100644 --- a/drivers/pci/quirks.c +++ b/drivers/pci/quirks.c | |||
@@ -2033,6 +2033,7 @@ DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_ATI, PCI_DEVICE_ID_ATI_RS400_200, quirk_di | |||
2033 | DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_ATI, PCI_DEVICE_ID_ATI_RS480, quirk_disable_all_msi); | 2033 | DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_ATI, PCI_DEVICE_ID_ATI_RS480, quirk_disable_all_msi); |
2034 | DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_VIA, PCI_DEVICE_ID_VIA_VT3336, quirk_disable_all_msi); | 2034 | DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_VIA, PCI_DEVICE_ID_VIA_VT3336, quirk_disable_all_msi); |
2035 | DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_VIA, PCI_DEVICE_ID_VIA_VT3351, quirk_disable_all_msi); | 2035 | DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_VIA, PCI_DEVICE_ID_VIA_VT3351, quirk_disable_all_msi); |
2036 | DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_VIA, PCI_DEVICE_ID_VIA_VT3364, quirk_disable_all_msi); | ||
2036 | 2037 | ||
2037 | /* Disable MSI on chipsets that are known to not support it */ | 2038 | /* Disable MSI on chipsets that are known to not support it */ |
2038 | static void __devinit quirk_disable_msi(struct pci_dev *dev) | 2039 | static void __devinit quirk_disable_msi(struct pci_dev *dev) |
diff --git a/drivers/pci/setup-bus.c b/drivers/pci/setup-bus.c index 8d9da9d30a61..a00f85471b6e 100644 --- a/drivers/pci/setup-bus.c +++ b/drivers/pci/setup-bus.c | |||
@@ -536,11 +536,13 @@ static void pci_bus_dump_res(struct pci_bus *bus) | |||
536 | 536 | ||
537 | for (i = 0; i < PCI_BUS_NUM_RESOURCES; i++) { | 537 | for (i = 0; i < PCI_BUS_NUM_RESOURCES; i++) { |
538 | struct resource *res = bus->resource[i]; | 538 | struct resource *res = bus->resource[i]; |
539 | if (!res) | 539 | if (!res || !res->end) |
540 | continue; | 540 | continue; |
541 | 541 | ||
542 | dev_printk(KERN_DEBUG, &bus->dev, "resource %d %s %pR\n", i, | 542 | dev_printk(KERN_DEBUG, &bus->dev, "resource %d %s %pR\n", i, |
543 | (res->flags & IORESOURCE_IO) ? "io: " : "mem:", res); | 543 | (res->flags & IORESOURCE_IO) ? "io: " : |
544 | ((res->flags & IORESOURCE_PREFETCH)? "pref mem":"mem:"), | ||
545 | res); | ||
544 | } | 546 | } |
545 | } | 547 | } |
546 | 548 | ||
diff --git a/drivers/pci/slot.c b/drivers/pci/slot.c index 21189447e545..fe95ce20bcbd 100644 --- a/drivers/pci/slot.c +++ b/drivers/pci/slot.c | |||
@@ -264,8 +264,8 @@ EXPORT_SYMBOL_GPL(pci_create_slot); | |||
264 | 264 | ||
265 | /** | 265 | /** |
266 | * pci_renumber_slot - update %struct pci_slot -> number | 266 | * pci_renumber_slot - update %struct pci_slot -> number |
267 | * @slot - %struct pci_slot to update | 267 | * @slot: &struct pci_slot to update |
268 | * @slot_nr - new number for slot | 268 | * @slot_nr: new number for slot |
269 | * | 269 | * |
270 | * The primary purpose of this interface is to allow callers who earlier | 270 | * The primary purpose of this interface is to allow callers who earlier |
271 | * created a placeholder slot in pci_create_slot() by passing a -1 as | 271 | * created a placeholder slot in pci_create_slot() by passing a -1 as |