aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/ata/ahci.c20
1 files changed, 18 insertions, 2 deletions
diff --git a/drivers/ata/ahci.c b/drivers/ata/ahci.c
index a3241a1a710b..9519c777af83 100644
--- a/drivers/ata/ahci.c
+++ b/drivers/ata/ahci.c
@@ -113,6 +113,7 @@ enum {
113 board_ahci_mcp65 = 6, 113 board_ahci_mcp65 = 6,
114 board_ahci_nopmp = 7, 114 board_ahci_nopmp = 7,
115 board_ahci_yesncq = 8, 115 board_ahci_yesncq = 8,
116 board_ahci_nosntf = 9,
116 117
117 /* global controller registers */ 118 /* global controller registers */
118 HOST_CAP = 0x00, /* host capabilities */ 119 HOST_CAP = 0x00, /* host capabilities */
@@ -235,6 +236,7 @@ enum {
235 AHCI_HFLAG_NO_SUSPEND = (1 << 10), /* don't suspend */ 236 AHCI_HFLAG_NO_SUSPEND = (1 << 10), /* don't suspend */
236 AHCI_HFLAG_SRST_TOUT_IS_OFFLINE = (1 << 11), /* treat SRST timeout as 237 AHCI_HFLAG_SRST_TOUT_IS_OFFLINE = (1 << 11), /* treat SRST timeout as
237 link offline */ 238 link offline */
239 AHCI_HFLAG_NO_SNTF = (1 << 12), /* no sntf */
238 240
239 /* ap->flags bits */ 241 /* ap->flags bits */
240 242
@@ -508,7 +510,7 @@ static const struct ata_port_info ahci_port_info[] = {
508 .udma_mask = ATA_UDMA6, 510 .udma_mask = ATA_UDMA6,
509 .port_ops = &ahci_ops, 511 .port_ops = &ahci_ops,
510 }, 512 },
511 /* board_ahci_yesncq */ 513 [board_ahci_yesncq] =
512 { 514 {
513 AHCI_HFLAGS (AHCI_HFLAG_YES_NCQ), 515 AHCI_HFLAGS (AHCI_HFLAG_YES_NCQ),
514 .flags = AHCI_FLAG_COMMON, 516 .flags = AHCI_FLAG_COMMON,
@@ -516,6 +518,14 @@ static const struct ata_port_info ahci_port_info[] = {
516 .udma_mask = ATA_UDMA6, 518 .udma_mask = ATA_UDMA6,
517 .port_ops = &ahci_ops, 519 .port_ops = &ahci_ops,
518 }, 520 },
521 [board_ahci_nosntf] =
522 {
523 AHCI_HFLAGS (AHCI_HFLAG_NO_SNTF),
524 .flags = AHCI_FLAG_COMMON,
525 .pio_mask = ATA_PIO4,
526 .udma_mask = ATA_UDMA6,
527 .port_ops = &ahci_ops,
528 },
519}; 529};
520 530
521static const struct pci_device_id ahci_pci_tbl[] = { 531static const struct pci_device_id ahci_pci_tbl[] = {
@@ -531,7 +541,7 @@ static const struct pci_device_id ahci_pci_tbl[] = {
531 { PCI_VDEVICE(INTEL, 0x2683), board_ahci }, /* ESB2 */ 541 { PCI_VDEVICE(INTEL, 0x2683), board_ahci }, /* ESB2 */
532 { PCI_VDEVICE(INTEL, 0x27c6), board_ahci }, /* ICH7-M DH */ 542 { PCI_VDEVICE(INTEL, 0x27c6), board_ahci }, /* ICH7-M DH */
533 { PCI_VDEVICE(INTEL, 0x2821), board_ahci }, /* ICH8 */ 543 { PCI_VDEVICE(INTEL, 0x2821), board_ahci }, /* ICH8 */
534 { PCI_VDEVICE(INTEL, 0x2822), board_ahci }, /* ICH8 */ 544 { PCI_VDEVICE(INTEL, 0x2822), board_ahci_nosntf }, /* ICH8 */
535 { PCI_VDEVICE(INTEL, 0x2824), board_ahci }, /* ICH8 */ 545 { PCI_VDEVICE(INTEL, 0x2824), board_ahci }, /* ICH8 */
536 { PCI_VDEVICE(INTEL, 0x2829), board_ahci }, /* ICH8M */ 546 { PCI_VDEVICE(INTEL, 0x2829), board_ahci }, /* ICH8M */
537 { PCI_VDEVICE(INTEL, 0x282a), board_ahci }, /* ICH8M */ 547 { PCI_VDEVICE(INTEL, 0x282a), board_ahci }, /* ICH8M */
@@ -849,6 +859,12 @@ static void ahci_save_initial_config(struct pci_dev *pdev,
849 cap &= ~HOST_CAP_PMP; 859 cap &= ~HOST_CAP_PMP;
850 } 860 }
851 861
862 if ((cap & HOST_CAP_SNTF) && (hpriv->flags & AHCI_HFLAG_NO_SNTF)) {
863 dev_printk(KERN_INFO, &pdev->dev,
864 "controller can't do SNTF, turning off CAP_SNTF\n");
865 cap &= ~HOST_CAP_SNTF;
866 }
867
852 if (pdev->vendor == PCI_VENDOR_ID_JMICRON && pdev->device == 0x2361 && 868 if (pdev->vendor == PCI_VENDOR_ID_JMICRON && pdev->device == 0x2361 &&
853 port_map != 1) { 869 port_map != 1) {
854 dev_printk(KERN_INFO, &pdev->dev, 870 dev_printk(KERN_INFO, &pdev->dev,