aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBjorn Helgaas <bhelgaas@google.com>2013-04-15 16:37:28 -0400
committerBjorn Helgaas <bhelgaas@google.com>2013-04-15 16:37:28 -0400
commit30e22b2337be44f4363fa52858d1ca7be6794ee8 (patch)
tree1a696e2750fa6967c8849f54fd9360c18b55a139
parent26c0995e6db6a0de55395aeac520ea74c81b82c3 (diff)
parent65195c76a7f855c879a168937f90a27032662328 (diff)
Merge branch 'pci/misc' into next
* pci/misc: PCI: Clean up quirk_io_region PCI: Use vma_pages() to replace (vm_end - vm_start) >> PAGE_SHIFT PCI: Use PCI_EXP_SLTCAP_PSN mask when extracting slot number PCI: Remove unnecessary dependencies between PME and ACPI [SCSI] mvumi: Use PCI_VENDOR_ID_MARVELL_EXT for 0x1b4b [SCSI] mvsas: Use PCI_VENDOR_ID_MARVELL_EXT for 0x1b4b ahci: Use PCI_VENDOR_ID_MARVELL_EXT for 0x1b4b PCI: Define macro for Marvell vendor ID PCI: Add MSI INTX_DISABLE quirks for AR8161/AR8162/AR8171/AR8172/E210X PCI: aer_inject: Fix return values when device not found
-rw-r--r--drivers/ata/ahci.c10
-rw-r--r--drivers/pci/hotplug/pciehp_acpi.c2
-rw-r--r--drivers/pci/pci-sysfs.c2
-rw-r--r--drivers/pci/pcie/Kconfig2
-rw-r--r--drivers/pci/pcie/aer/aer_inject.c6
-rw-r--r--drivers/pci/pcie/pme.c2
-rw-r--r--drivers/pci/quirks.c148
-rw-r--r--drivers/scsi/mvsas/mv_init.c6
-rw-r--r--drivers/scsi/mvumi.c4
-rw-r--r--drivers/scsi/mvumi.h1
-rw-r--r--include/linux/pci_ids.h1
11 files changed, 80 insertions, 104 deletions
diff --git a/drivers/ata/ahci.c b/drivers/ata/ahci.c
index a99112cfd8b1..616952facd6e 100644
--- a/drivers/ata/ahci.c
+++ b/drivers/ata/ahci.c
@@ -413,17 +413,17 @@ static const struct pci_device_id ahci_pci_tbl[] = {
413 /* Marvell */ 413 /* Marvell */
414 { PCI_VDEVICE(MARVELL, 0x6145), board_ahci_mv }, /* 6145 */ 414 { PCI_VDEVICE(MARVELL, 0x6145), board_ahci_mv }, /* 6145 */
415 { PCI_VDEVICE(MARVELL, 0x6121), board_ahci_mv }, /* 6121 */ 415 { PCI_VDEVICE(MARVELL, 0x6121), board_ahci_mv }, /* 6121 */
416 { PCI_DEVICE(0x1b4b, 0x9123), 416 { PCI_DEVICE(PCI_VENDOR_ID_MARVELL_EXT, 0x9123),
417 .class = PCI_CLASS_STORAGE_SATA_AHCI, 417 .class = PCI_CLASS_STORAGE_SATA_AHCI,
418 .class_mask = 0xffffff, 418 .class_mask = 0xffffff,
419 .driver_data = board_ahci_yes_fbs }, /* 88se9128 */ 419 .driver_data = board_ahci_yes_fbs }, /* 88se9128 */
420 { PCI_DEVICE(0x1b4b, 0x9125), 420 { PCI_DEVICE(PCI_VENDOR_ID_MARVELL_EXT, 0x9125),
421 .driver_data = board_ahci_yes_fbs }, /* 88se9125 */ 421 .driver_data = board_ahci_yes_fbs }, /* 88se9125 */
422 { PCI_DEVICE(0x1b4b, 0x917a), 422 { PCI_DEVICE(PCI_VENDOR_ID_MARVELL_EXT, 0x917a),
423 .driver_data = board_ahci_yes_fbs }, /* 88se9172 */ 423 .driver_data = board_ahci_yes_fbs }, /* 88se9172 */
424 { PCI_DEVICE(0x1b4b, 0x9192), 424 { PCI_DEVICE(PCI_VENDOR_ID_MARVELL_EXT, 0x9192),
425 .driver_data = board_ahci_yes_fbs }, /* 88se9172 on some Gigabyte */ 425 .driver_data = board_ahci_yes_fbs }, /* 88se9172 on some Gigabyte */
426 { PCI_DEVICE(0x1b4b, 0x91a3), 426 { PCI_DEVICE(PCI_VENDOR_ID_MARVELL_EXT, 0x91a3),
427 .driver_data = board_ahci_yes_fbs }, 427 .driver_data = board_ahci_yes_fbs },
428 428
429 /* Promise */ 429 /* Promise */
diff --git a/drivers/pci/hotplug/pciehp_acpi.c b/drivers/pci/hotplug/pciehp_acpi.c
index 24d709b7388c..ead7c534095e 100644
--- a/drivers/pci/hotplug/pciehp_acpi.c
+++ b/drivers/pci/hotplug/pciehp_acpi.c
@@ -90,7 +90,7 @@ static int __init dummy_probe(struct pcie_device *dev)
90 slot = kzalloc(sizeof(*slot), GFP_KERNEL); 90 slot = kzalloc(sizeof(*slot), GFP_KERNEL);
91 if (!slot) 91 if (!slot)
92 return -ENOMEM; 92 return -ENOMEM;
93 slot->number = slot_cap >> 19; 93 slot->number = (slot_cap & PCI_EXP_SLTCAP_PSN) >> 19;
94 list_for_each_entry(tmp, &dummy_slots, list) { 94 list_for_each_entry(tmp, &dummy_slots, list) {
95 if (tmp->number == slot->number) 95 if (tmp->number == slot->number)
96 dup_slot_id++; 96 dup_slot_id++;
diff --git a/drivers/pci/pci-sysfs.c b/drivers/pci/pci-sysfs.c
index 9c6e9bb674ec..5b4a9d9cd200 100644
--- a/drivers/pci/pci-sysfs.c
+++ b/drivers/pci/pci-sysfs.c
@@ -897,7 +897,7 @@ int pci_mmap_fits(struct pci_dev *pdev, int resno, struct vm_area_struct *vma,
897 897
898 if (pci_resource_len(pdev, resno) == 0) 898 if (pci_resource_len(pdev, resno) == 0)
899 return 0; 899 return 0;
900 nr = (vma->vm_end - vma->vm_start) >> PAGE_SHIFT; 900 nr = vma_pages(vma);
901 start = vma->vm_pgoff; 901 start = vma->vm_pgoff;
902 size = ((pci_resource_len(pdev, resno) - 1) >> PAGE_SHIFT) + 1; 902 size = ((pci_resource_len(pdev, resno) - 1) >> PAGE_SHIFT) + 1;
903 pci_start = (mmap_api == PCI_MMAP_PROCFS) ? 903 pci_start = (mmap_api == PCI_MMAP_PROCFS) ?
diff --git a/drivers/pci/pcie/Kconfig b/drivers/pci/pcie/Kconfig
index fde4a32a0295..569f82fc9e22 100644
--- a/drivers/pci/pcie/Kconfig
+++ b/drivers/pci/pcie/Kconfig
@@ -82,4 +82,4 @@ endchoice
82 82
83config PCIE_PME 83config PCIE_PME
84 def_bool y 84 def_bool y
85 depends on PCIEPORTBUS && PM_RUNTIME && ACPI 85 depends on PCIEPORTBUS && PM_RUNTIME
diff --git a/drivers/pci/pcie/aer/aer_inject.c b/drivers/pci/pcie/aer/aer_inject.c
index 4e24cb8a94ae..8d4a5e3dbe8e 100644
--- a/drivers/pci/pcie/aer/aer_inject.c
+++ b/drivers/pci/pcie/aer/aer_inject.c
@@ -334,13 +334,13 @@ static int aer_inject(struct aer_error_inj *einj)
334 return -ENODEV; 334 return -ENODEV;
335 rpdev = pcie_find_root_port(dev); 335 rpdev = pcie_find_root_port(dev);
336 if (!rpdev) { 336 if (!rpdev) {
337 ret = -ENOTTY; 337 ret = -ENODEV;
338 goto out_put; 338 goto out_put;
339 } 339 }
340 340
341 pos_cap_err = pci_find_ext_capability(dev, PCI_EXT_CAP_ID_ERR); 341 pos_cap_err = pci_find_ext_capability(dev, PCI_EXT_CAP_ID_ERR);
342 if (!pos_cap_err) { 342 if (!pos_cap_err) {
343 ret = -ENOTTY; 343 ret = -EPERM;
344 goto out_put; 344 goto out_put;
345 } 345 }
346 pci_read_config_dword(dev, pos_cap_err + PCI_ERR_UNCOR_SEVER, &sever); 346 pci_read_config_dword(dev, pos_cap_err + PCI_ERR_UNCOR_SEVER, &sever);
@@ -350,7 +350,7 @@ static int aer_inject(struct aer_error_inj *einj)
350 350
351 rp_pos_cap_err = pci_find_ext_capability(rpdev, PCI_EXT_CAP_ID_ERR); 351 rp_pos_cap_err = pci_find_ext_capability(rpdev, PCI_EXT_CAP_ID_ERR);
352 if (!rp_pos_cap_err) { 352 if (!rp_pos_cap_err) {
353 ret = -ENOTTY; 353 ret = -EPERM;
354 goto out_put; 354 goto out_put;
355 } 355 }
356 356
diff --git a/drivers/pci/pcie/pme.c b/drivers/pci/pcie/pme.c
index 9ca0dc9ffd84..795db1f9d50c 100644
--- a/drivers/pci/pcie/pme.c
+++ b/drivers/pci/pcie/pme.c
@@ -19,8 +19,6 @@
19#include <linux/interrupt.h> 19#include <linux/interrupt.h>
20#include <linux/device.h> 20#include <linux/device.h>
21#include <linux/pcieport_if.h> 21#include <linux/pcieport_if.h>
22#include <linux/acpi.h>
23#include <linux/pci-acpi.h>
24#include <linux/pm_runtime.h> 22#include <linux/pm_runtime.h>
25 23
26#include "../pci.h" 24#include "../pci.h"
diff --git a/drivers/pci/quirks.c b/drivers/pci/quirks.c
index 0369fb6fc1da..7d68aeebf56b 100644
--- a/drivers/pci/quirks.c
+++ b/drivers/pci/quirks.c
@@ -324,29 +324,30 @@ static void quirk_cs5536_vsa(struct pci_dev *dev)
324} 324}
325DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_CS5536_ISA, quirk_cs5536_vsa); 325DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_CS5536_ISA, quirk_cs5536_vsa);
326 326
327static void quirk_io_region(struct pci_dev *dev, unsigned region, 327static void quirk_io_region(struct pci_dev *dev, int port,
328 unsigned size, int nr, const char *name) 328 unsigned size, int nr, const char *name)
329{ 329{
330 region &= ~(size-1); 330 u16 region;
331 if (region) { 331 struct pci_bus_region bus_region;
332 struct pci_bus_region bus_region; 332 struct resource *res = dev->resource + nr;
333 struct resource *res = dev->resource + nr;
334 333
335 res->name = pci_name(dev); 334 pci_read_config_word(dev, port, &region);
336 res->start = region; 335 region &= ~(size - 1);
337 res->end = region + size - 1;
338 res->flags = IORESOURCE_IO;
339 336
340 /* Convert from PCI bus to resource space. */ 337 if (!region)
341 bus_region.start = res->start; 338 return;
342 bus_region.end = res->end;
343 pcibios_bus_to_resource(dev, res, &bus_region);
344 339
345 if (pci_claim_resource(dev, nr) == 0) 340 res->name = pci_name(dev);
346 dev_info(&dev->dev, "quirk: %pR claimed by %s\n", 341 res->flags = IORESOURCE_IO;
347 res, name); 342
348 } 343 /* Convert from PCI bus to resource space */
349} 344 bus_region.start = region;
345 bus_region.end = region + size - 1;
346 pcibios_bus_to_resource(dev, res, &bus_region);
347
348 if (!pci_claim_resource(dev, nr))
349 dev_info(&dev->dev, "quirk: %pR claimed by %s\n", res, name);
350}
350 351
351/* 352/*
352 * ATI Northbridge setups MCE the processor if you even 353 * ATI Northbridge setups MCE the processor if you even
@@ -374,12 +375,8 @@ DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_ATI, PCI_DEVICE_ID_ATI_RS100, quirk_ati_
374 */ 375 */
375static void quirk_ali7101_acpi(struct pci_dev *dev) 376static void quirk_ali7101_acpi(struct pci_dev *dev)
376{ 377{
377 u16 region; 378 quirk_io_region(dev, 0xE0, 64, PCI_BRIDGE_RESOURCES, "ali7101 ACPI");
378 379 quirk_io_region(dev, 0xE2, 32, PCI_BRIDGE_RESOURCES+1, "ali7101 SMB");
379 pci_read_config_word(dev, 0xE0, &region);
380 quirk_io_region(dev, region, 64, PCI_BRIDGE_RESOURCES, "ali7101 ACPI");
381 pci_read_config_word(dev, 0xE2, &region);
382 quirk_io_region(dev, region, 32, PCI_BRIDGE_RESOURCES+1, "ali7101 SMB");
383} 380}
384DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_AL, PCI_DEVICE_ID_AL_M7101, quirk_ali7101_acpi); 381DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_AL, PCI_DEVICE_ID_AL_M7101, quirk_ali7101_acpi);
385 382
@@ -442,12 +439,10 @@ static void piix4_mem_quirk(struct pci_dev *dev, const char *name, unsigned int
442 */ 439 */
443static void quirk_piix4_acpi(struct pci_dev *dev) 440static void quirk_piix4_acpi(struct pci_dev *dev)
444{ 441{
445 u32 region, res_a; 442 u32 res_a;
446 443
447 pci_read_config_dword(dev, 0x40, &region); 444 quirk_io_region(dev, 0x40, 64, PCI_BRIDGE_RESOURCES, "PIIX4 ACPI");
448 quirk_io_region(dev, region, 64, PCI_BRIDGE_RESOURCES, "PIIX4 ACPI"); 445 quirk_io_region(dev, 0x90, 16, PCI_BRIDGE_RESOURCES+1, "PIIX4 SMB");
449 pci_read_config_dword(dev, 0x90, &region);
450 quirk_io_region(dev, region, 16, PCI_BRIDGE_RESOURCES+1, "PIIX4 SMB");
451 446
452 /* Device resource A has enables for some of the other ones */ 447 /* Device resource A has enables for some of the other ones */
453 pci_read_config_dword(dev, 0x5c, &res_a); 448 pci_read_config_dword(dev, 0x5c, &res_a);
@@ -491,7 +486,6 @@ DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_82443MX_3, qui
491 */ 486 */
492static void quirk_ich4_lpc_acpi(struct pci_dev *dev) 487static void quirk_ich4_lpc_acpi(struct pci_dev *dev)
493{ 488{
494 u32 region;
495 u8 enable; 489 u8 enable;
496 490
497 /* 491 /*
@@ -503,22 +497,14 @@ static void quirk_ich4_lpc_acpi(struct pci_dev *dev)
503 */ 497 */
504 498
505 pci_read_config_byte(dev, ICH_ACPI_CNTL, &enable); 499 pci_read_config_byte(dev, ICH_ACPI_CNTL, &enable);
506 if (enable & ICH4_ACPI_EN) { 500 if (enable & ICH4_ACPI_EN)
507 pci_read_config_dword(dev, ICH_PMBASE, &region); 501 quirk_io_region(dev, ICH_PMBASE, 128, PCI_BRIDGE_RESOURCES,
508 region &= PCI_BASE_ADDRESS_IO_MASK; 502 "ICH4 ACPI/GPIO/TCO");
509 if (region >= PCIBIOS_MIN_IO)
510 quirk_io_region(dev, region, 128, PCI_BRIDGE_RESOURCES,
511 "ICH4 ACPI/GPIO/TCO");
512 }
513 503
514 pci_read_config_byte(dev, ICH4_GPIO_CNTL, &enable); 504 pci_read_config_byte(dev, ICH4_GPIO_CNTL, &enable);
515 if (enable & ICH4_GPIO_EN) { 505 if (enable & ICH4_GPIO_EN)
516 pci_read_config_dword(dev, ICH4_GPIOBASE, &region); 506 quirk_io_region(dev, ICH4_GPIOBASE, 64, PCI_BRIDGE_RESOURCES+1,
517 region &= PCI_BASE_ADDRESS_IO_MASK; 507 "ICH4 GPIO");
518 if (region >= PCIBIOS_MIN_IO)
519 quirk_io_region(dev, region, 64,
520 PCI_BRIDGE_RESOURCES + 1, "ICH4 GPIO");
521 }
522} 508}
523DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_82801AA_0, quirk_ich4_lpc_acpi); 509DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_82801AA_0, quirk_ich4_lpc_acpi);
524DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_82801AB_0, quirk_ich4_lpc_acpi); 510DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_82801AB_0, quirk_ich4_lpc_acpi);
@@ -533,26 +519,17 @@ DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_ESB_1, qui
533 519
534static void ich6_lpc_acpi_gpio(struct pci_dev *dev) 520static void ich6_lpc_acpi_gpio(struct pci_dev *dev)
535{ 521{
536 u32 region;
537 u8 enable; 522 u8 enable;
538 523
539 pci_read_config_byte(dev, ICH_ACPI_CNTL, &enable); 524 pci_read_config_byte(dev, ICH_ACPI_CNTL, &enable);
540 if (enable & ICH6_ACPI_EN) { 525 if (enable & ICH6_ACPI_EN)
541 pci_read_config_dword(dev, ICH_PMBASE, &region); 526 quirk_io_region(dev, ICH_PMBASE, 128, PCI_BRIDGE_RESOURCES,
542 region &= PCI_BASE_ADDRESS_IO_MASK; 527 "ICH6 ACPI/GPIO/TCO");
543 if (region >= PCIBIOS_MIN_IO)
544 quirk_io_region(dev, region, 128, PCI_BRIDGE_RESOURCES,
545 "ICH6 ACPI/GPIO/TCO");
546 }
547 528
548 pci_read_config_byte(dev, ICH6_GPIO_CNTL, &enable); 529 pci_read_config_byte(dev, ICH6_GPIO_CNTL, &enable);
549 if (enable & ICH6_GPIO_EN) { 530 if (enable & ICH6_GPIO_EN)
550 pci_read_config_dword(dev, ICH6_GPIOBASE, &region); 531 quirk_io_region(dev, ICH6_GPIOBASE, 64, PCI_BRIDGE_RESOURCES+1,
551 region &= PCI_BASE_ADDRESS_IO_MASK; 532 "ICH6 GPIO");
552 if (region >= PCIBIOS_MIN_IO)
553 quirk_io_region(dev, region, 64,
554 PCI_BRIDGE_RESOURCES + 1, "ICH6 GPIO");
555 }
556} 533}
557 534
558static void ich6_lpc_generic_decode(struct pci_dev *dev, unsigned reg, const char *name, int dynsize) 535static void ich6_lpc_generic_decode(struct pci_dev *dev, unsigned reg, const char *name, int dynsize)
@@ -650,13 +627,9 @@ DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_ICH10_1, qui
650 */ 627 */
651static void quirk_vt82c586_acpi(struct pci_dev *dev) 628static void quirk_vt82c586_acpi(struct pci_dev *dev)
652{ 629{
653 u32 region; 630 if (dev->revision & 0x10)
654 631 quirk_io_region(dev, 0x48, 256, PCI_BRIDGE_RESOURCES,
655 if (dev->revision & 0x10) { 632 "vt82c586 ACPI");
656 pci_read_config_dword(dev, 0x48, &region);
657 region &= PCI_BASE_ADDRESS_IO_MASK;
658 quirk_io_region(dev, region, 256, PCI_BRIDGE_RESOURCES, "vt82c586 ACPI");
659 }
660} 633}
661DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_VIA, PCI_DEVICE_ID_VIA_82C586_3, quirk_vt82c586_acpi); 634DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_VIA, PCI_DEVICE_ID_VIA_82C586_3, quirk_vt82c586_acpi);
662 635
@@ -668,18 +641,12 @@ DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_VIA, PCI_DEVICE_ID_VIA_82C586_3, quirk_vt
668 */ 641 */
669static void quirk_vt82c686_acpi(struct pci_dev *dev) 642static void quirk_vt82c686_acpi(struct pci_dev *dev)
670{ 643{
671 u16 hm;
672 u32 smb;
673
674 quirk_vt82c586_acpi(dev); 644 quirk_vt82c586_acpi(dev);
675 645
676 pci_read_config_word(dev, 0x70, &hm); 646 quirk_io_region(dev, 0x70, 128, PCI_BRIDGE_RESOURCES+1,
677 hm &= PCI_BASE_ADDRESS_IO_MASK; 647 "vt82c686 HW-mon");
678 quirk_io_region(dev, hm, 128, PCI_BRIDGE_RESOURCES + 1, "vt82c686 HW-mon");
679 648
680 pci_read_config_dword(dev, 0x90, &smb); 649 quirk_io_region(dev, 0x90, 16, PCI_BRIDGE_RESOURCES+2, "vt82c686 SMB");
681 smb &= PCI_BASE_ADDRESS_IO_MASK;
682 quirk_io_region(dev, smb, 16, PCI_BRIDGE_RESOURCES + 2, "vt82c686 SMB");
683} 650}
684DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_VIA, PCI_DEVICE_ID_VIA_82C686_4, quirk_vt82c686_acpi); 651DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_VIA, PCI_DEVICE_ID_VIA_82C686_4, quirk_vt82c686_acpi);
685 652
@@ -690,15 +657,8 @@ DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_VIA, PCI_DEVICE_ID_VIA_82C686_4, quirk_vt
690 */ 657 */
691static void quirk_vt8235_acpi(struct pci_dev *dev) 658static void quirk_vt8235_acpi(struct pci_dev *dev)
692{ 659{
693 u16 pm, smb; 660 quirk_io_region(dev, 0x88, 128, PCI_BRIDGE_RESOURCES, "vt8235 PM");
694 661 quirk_io_region(dev, 0xd0, 16, PCI_BRIDGE_RESOURCES+1, "vt8235 SMB");
695 pci_read_config_word(dev, 0x88, &pm);
696 pm &= PCI_BASE_ADDRESS_IO_MASK;
697 quirk_io_region(dev, pm, 128, PCI_BRIDGE_RESOURCES, "vt8235 PM");
698
699 pci_read_config_word(dev, 0xd0, &smb);
700 smb &= PCI_BASE_ADDRESS_IO_MASK;
701 quirk_io_region(dev, smb, 16, PCI_BRIDGE_RESOURCES + 1, "vt8235 SMB");
702} 662}
703DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_VIA, PCI_DEVICE_ID_VIA_8235, quirk_vt8235_acpi); 663DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_VIA, PCI_DEVICE_ID_VIA_8235, quirk_vt8235_acpi);
704 664
@@ -2594,6 +2554,14 @@ static void quirk_msi_intx_disable_ati_bug(struct pci_dev *dev)
2594 dev->dev_flags |= PCI_DEV_FLAGS_MSI_INTX_DISABLE_BUG; 2554 dev->dev_flags |= PCI_DEV_FLAGS_MSI_INTX_DISABLE_BUG;
2595 pci_dev_put(p); 2555 pci_dev_put(p);
2596} 2556}
2557static void quirk_msi_intx_disable_qca_bug(struct pci_dev *dev)
2558{
2559 /* AR816X/AR817X/E210X MSI is fixed at HW level from revision 0x18 */
2560 if (dev->revision < 0x18) {
2561 dev_info(&dev->dev, "set MSI_INTX_DISABLE_BUG flag\n");
2562 dev->dev_flags |= PCI_DEV_FLAGS_MSI_INTX_DISABLE_BUG;
2563 }
2564}
2597DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_BROADCOM, 2565DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_BROADCOM,
2598 PCI_DEVICE_ID_TIGON3_5780, 2566 PCI_DEVICE_ID_TIGON3_5780,
2599 quirk_msi_intx_disable_bug); 2567 quirk_msi_intx_disable_bug);
@@ -2643,6 +2611,16 @@ DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_ATTANSIC, 0x1073,
2643 quirk_msi_intx_disable_bug); 2611 quirk_msi_intx_disable_bug);
2644DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_ATTANSIC, 0x1083, 2612DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_ATTANSIC, 0x1083,
2645 quirk_msi_intx_disable_bug); 2613 quirk_msi_intx_disable_bug);
2614DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_ATTANSIC, 0x1090,
2615 quirk_msi_intx_disable_qca_bug);
2616DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_ATTANSIC, 0x1091,
2617 quirk_msi_intx_disable_qca_bug);
2618DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_ATTANSIC, 0x10a0,
2619 quirk_msi_intx_disable_qca_bug);
2620DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_ATTANSIC, 0x10a1,
2621 quirk_msi_intx_disable_qca_bug);
2622DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_ATTANSIC, 0xe091,
2623 quirk_msi_intx_disable_qca_bug);
2646#endif /* CONFIG_PCI_MSI */ 2624#endif /* CONFIG_PCI_MSI */
2647 2625
2648/* Allow manual resource allocation for PCI hotplug bridges 2626/* Allow manual resource allocation for PCI hotplug bridges
diff --git a/drivers/scsi/mvsas/mv_init.c b/drivers/scsi/mvsas/mv_init.c
index ce90d0546cdd..74550922ad55 100644
--- a/drivers/scsi/mvsas/mv_init.c
+++ b/drivers/scsi/mvsas/mv_init.c
@@ -703,7 +703,7 @@ static struct pci_device_id mvs_pci_table[] = {
703 { PCI_VDEVICE(TTI, 0x2744), chip_9480 }, 703 { PCI_VDEVICE(TTI, 0x2744), chip_9480 },
704 { PCI_VDEVICE(TTI, 0x2760), chip_9480 }, 704 { PCI_VDEVICE(TTI, 0x2760), chip_9480 },
705 { 705 {
706 .vendor = 0x1b4b, 706 .vendor = PCI_VENDOR_ID_MARVELL_EXT,
707 .device = 0x9480, 707 .device = 0x9480,
708 .subvendor = PCI_ANY_ID, 708 .subvendor = PCI_ANY_ID,
709 .subdevice = 0x9480, 709 .subdevice = 0x9480,
@@ -712,7 +712,7 @@ static struct pci_device_id mvs_pci_table[] = {
712 .driver_data = chip_9480, 712 .driver_data = chip_9480,
713 }, 713 },
714 { 714 {
715 .vendor = 0x1b4b, 715 .vendor = PCI_VENDOR_ID_MARVELL_EXT,
716 .device = 0x9445, 716 .device = 0x9445,
717 .subvendor = PCI_ANY_ID, 717 .subvendor = PCI_ANY_ID,
718 .subdevice = 0x9480, 718 .subdevice = 0x9480,
@@ -721,7 +721,7 @@ static struct pci_device_id mvs_pci_table[] = {
721 .driver_data = chip_9445, 721 .driver_data = chip_9445,
722 }, 722 },
723 { 723 {
724 .vendor = 0x1b4b, 724 .vendor = PCI_VENDOR_ID_MARVELL_EXT,
725 .device = 0x9485, 725 .device = 0x9485,
726 .subvendor = PCI_ANY_ID, 726 .subvendor = PCI_ANY_ID,
727 .subdevice = 0x9480, 727 .subdevice = 0x9480,
diff --git a/drivers/scsi/mvumi.c b/drivers/scsi/mvumi.c
index 4594ccaaf49b..c3601b57a80c 100644
--- a/drivers/scsi/mvumi.c
+++ b/drivers/scsi/mvumi.c
@@ -49,8 +49,8 @@ MODULE_AUTHOR("jyli@marvell.com");
49MODULE_DESCRIPTION("Marvell UMI Driver"); 49MODULE_DESCRIPTION("Marvell UMI Driver");
50 50
51static DEFINE_PCI_DEVICE_TABLE(mvumi_pci_table) = { 51static DEFINE_PCI_DEVICE_TABLE(mvumi_pci_table) = {
52 { PCI_DEVICE(PCI_VENDOR_ID_MARVELL_2, PCI_DEVICE_ID_MARVELL_MV9143) }, 52 { PCI_DEVICE(PCI_VENDOR_ID_MARVELL_EXT, PCI_DEVICE_ID_MARVELL_MV9143) },
53 { PCI_DEVICE(PCI_VENDOR_ID_MARVELL_2, PCI_DEVICE_ID_MARVELL_MV9580) }, 53 { PCI_DEVICE(PCI_VENDOR_ID_MARVELL_EXT, PCI_DEVICE_ID_MARVELL_MV9580) },
54 { 0 } 54 { 0 }
55}; 55};
56 56
diff --git a/drivers/scsi/mvumi.h b/drivers/scsi/mvumi.h
index e360135fd1bd..41f168702ac7 100644
--- a/drivers/scsi/mvumi.h
+++ b/drivers/scsi/mvumi.h
@@ -32,7 +32,6 @@
32#define VER_BUILD 1500 32#define VER_BUILD 1500
33 33
34#define MV_DRIVER_NAME "mvumi" 34#define MV_DRIVER_NAME "mvumi"
35#define PCI_VENDOR_ID_MARVELL_2 0x1b4b
36#define PCI_DEVICE_ID_MARVELL_MV9143 0x9143 35#define PCI_DEVICE_ID_MARVELL_MV9143 0x9143
37#define PCI_DEVICE_ID_MARVELL_MV9580 0x9580 36#define PCI_DEVICE_ID_MARVELL_MV9580 0x9580
38 37
diff --git a/include/linux/pci_ids.h b/include/linux/pci_ids.h
index f11c1c2609d5..a80f9e6ce9e5 100644
--- a/include/linux/pci_ids.h
+++ b/include/linux/pci_ids.h
@@ -1604,6 +1604,7 @@
1604#define PCI_SUBDEVICE_ID_KEYSPAN_SX2 0x5334 1604#define PCI_SUBDEVICE_ID_KEYSPAN_SX2 0x5334
1605 1605
1606#define PCI_VENDOR_ID_MARVELL 0x11ab 1606#define PCI_VENDOR_ID_MARVELL 0x11ab
1607#define PCI_VENDOR_ID_MARVELL_EXT 0x1b4b
1607#define PCI_DEVICE_ID_MARVELL_GT64111 0x4146 1608#define PCI_DEVICE_ID_MARVELL_GT64111 0x4146
1608#define PCI_DEVICE_ID_MARVELL_GT64260 0x6430 1609#define PCI_DEVICE_ID_MARVELL_GT64260 0x6430
1609#define PCI_DEVICE_ID_MARVELL_MV64360 0x6460 1610#define PCI_DEVICE_ID_MARVELL_MV64360 0x6460