Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

Merge branch 'for-4.5-fixes' into for-4.6

Tejun Heo fe6c5814 51b1b286

+61 -4
+49
drivers/ata/ahci.c
··· 372 372 { PCI_VDEVICE(INTEL, 0xa107), board_ahci }, /* Sunrise Point-H RAID */ 373 373 { PCI_VDEVICE(INTEL, 0xa10f), board_ahci }, /* Sunrise Point-H RAID */ 374 374 { PCI_VDEVICE(INTEL, 0x2822), board_ahci }, /* Lewisburg RAID*/ 375 + { PCI_VDEVICE(INTEL, 0x2823), board_ahci }, /* Lewisburg AHCI*/ 375 376 { PCI_VDEVICE(INTEL, 0x2826), board_ahci }, /* Lewisburg RAID*/ 377 + { PCI_VDEVICE(INTEL, 0x2827), board_ahci }, /* Lewisburg RAID*/ 376 378 { PCI_VDEVICE(INTEL, 0xa182), board_ahci }, /* Lewisburg AHCI*/ 377 379 { PCI_VDEVICE(INTEL, 0xa184), board_ahci }, /* Lewisburg RAID*/ 378 380 { PCI_VDEVICE(INTEL, 0xa186), board_ahci }, /* Lewisburg RAID*/ 379 381 { PCI_VDEVICE(INTEL, 0xa18e), board_ahci }, /* Lewisburg RAID*/ 382 + { PCI_VDEVICE(INTEL, 0xa1d2), board_ahci }, /* Lewisburg RAID*/ 383 + { PCI_VDEVICE(INTEL, 0xa1d6), board_ahci }, /* Lewisburg RAID*/ 380 384 { PCI_VDEVICE(INTEL, 0xa202), board_ahci }, /* Lewisburg AHCI*/ 381 385 { PCI_VDEVICE(INTEL, 0xa204), board_ahci }, /* Lewisburg RAID*/ 382 386 { PCI_VDEVICE(INTEL, 0xa206), board_ahci }, /* Lewisburg RAID*/ 383 387 { PCI_VDEVICE(INTEL, 0xa20e), board_ahci }, /* Lewisburg RAID*/ 388 + { PCI_VDEVICE(INTEL, 0xa252), board_ahci }, /* Lewisburg RAID*/ 389 + { PCI_VDEVICE(INTEL, 0xa256), board_ahci }, /* Lewisburg RAID*/ 384 390 385 391 /* JMicron 360/1/3/5/6, match class to avoid IDE function */ 386 392 { PCI_VENDOR_ID_JMICRON, PCI_ANY_ID, PCI_ANY_ID, PCI_ANY_ID, ··· 1366 1360 {} 1367 1361 #endif 1368 1362 1363 + #ifdef CONFIG_ARM64 1364 + /* 1365 + * Due to ERRATA#22536, ThunderX needs to handle HOST_IRQ_STAT differently. 1366 + * Workaround is to make sure all pending IRQs are served before leaving 1367 + * handler. 1368 + */ 1369 + static irqreturn_t ahci_thunderx_irq_handler(int irq, void *dev_instance) 1370 + { 1371 + struct ata_host *host = dev_instance; 1372 + struct ahci_host_priv *hpriv; 1373 + unsigned int rc = 0; 1374 + void __iomem *mmio; 1375 + u32 irq_stat, irq_masked; 1376 + unsigned int handled = 1; 1377 + 1378 + VPRINTK("ENTER\n"); 1379 + hpriv = host->private_data; 1380 + mmio = hpriv->mmio; 1381 + irq_stat = readl(mmio + HOST_IRQ_STAT); 1382 + if (!irq_stat) 1383 + return IRQ_NONE; 1384 + 1385 + do { 1386 + irq_masked = irq_stat & hpriv->port_map; 1387 + spin_lock(&host->lock); 1388 + rc = ahci_handle_port_intr(host, irq_masked); 1389 + if (!rc) 1390 + handled = 0; 1391 + writel(irq_stat, mmio + HOST_IRQ_STAT); 1392 + irq_stat = readl(mmio + HOST_IRQ_STAT); 1393 + spin_unlock(&host->lock); 1394 + } while (irq_stat); 1395 + VPRINTK("EXIT\n"); 1396 + 1397 + return IRQ_RETVAL(handled); 1398 + } 1399 + #endif 1400 + 1369 1401 /* 1370 1402 * ahci_init_msix() - optionally enable per-port MSI-X otherwise defer 1371 1403 * to single msi. ··· 1638 1594 /* must set flag prior to save config in order to take effect */ 1639 1595 if (ahci_broken_devslp(pdev)) 1640 1596 hpriv->flags |= AHCI_HFLAG_NO_DEVSLP; 1597 + 1598 + #ifdef CONFIG_ARM64 1599 + if (pdev->vendor == 0x177d && pdev->device == 0xa01c) 1600 + hpriv->irq_handler = ahci_thunderx_irq_handler; 1601 + #endif 1641 1602 1642 1603 /* save initial config */ 1643 1604 ahci_pci_save_initial_config(pdev, hpriv);
+1 -2
drivers/ata/libahci.c
··· 1211 1211 1212 1212 /* mark esata ports */ 1213 1213 tmp = readl(port_mmio + PORT_CMD); 1214 - if ((tmp & PORT_CMD_HPCP) || 1215 - ((tmp & PORT_CMD_ESP) && (hpriv->cap & HOST_CAP_SXS))) 1214 + if ((tmp & PORT_CMD_ESP) && (hpriv->cap & HOST_CAP_SXS)) 1216 1215 ap->pflags |= ATA_PFLAG_EXTERNAL; 1217 1216 } 1218 1217
+10 -1
drivers/ata/pata_rb532_cf.c
··· 32 32 #include <linux/libata.h> 33 33 #include <scsi/scsi_host.h> 34 34 35 + #include <asm/mach-rc32434/rb.h> 36 + 35 37 #define DRV_NAME "pata-rb532-cf" 36 38 #define DRV_VERSION "0.1.0" 37 39 #define DRV_DESC "PATA driver for RouterBOARD 532 Compact Flash" ··· 109 107 int gpio; 110 108 struct resource *res; 111 109 struct ata_host *ah; 110 + struct cf_device *pdata; 112 111 struct rb532_cf_info *info; 113 112 int ret; 114 113 ··· 125 122 return -ENOENT; 126 123 } 127 124 128 - gpio = irq_to_gpio(irq); 125 + pdata = dev_get_platdata(&pdev->dev); 126 + if (!pdata) { 127 + dev_err(&pdev->dev, "no platform data specified\n"); 128 + return -EINVAL; 129 + } 130 + 131 + gpio = pdata->gpio_pin; 129 132 if (gpio < 0) { 130 133 dev_err(&pdev->dev, "no GPIO found for irq%d\n", irq); 131 134 return -ENOENT;
+1 -1
include/linux/libata.h
··· 720 720 union { 721 721 u16 id[ATA_ID_WORDS]; /* IDENTIFY xxx DEVICE data */ 722 722 u32 gscr[SATA_PMP_GSCR_DWORDS]; /* PMP GSCR block */ 723 - }; 723 + } ____cacheline_aligned; 724 724 725 725 /* DEVSLP Timing Variables from Identify Device Data Log */ 726 726 u8 devslp_timing[ATA_LOG_DEVSLP_SIZE];