diff options
Diffstat (limited to 'drivers/ata/ahci.c')
-rw-r--r-- | drivers/ata/ahci.c | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/drivers/ata/ahci.c b/drivers/ata/ahci.c index 29e71bddd6ff..6dd12f7019a0 100644 --- a/drivers/ata/ahci.c +++ b/drivers/ata/ahci.c | |||
@@ -1932,7 +1932,7 @@ static int ahci_pci_device_suspend(struct pci_dev *pdev, pm_message_t mesg) | |||
1932 | void __iomem *mmio = host->iomap[AHCI_PCI_BAR]; | 1932 | void __iomem *mmio = host->iomap[AHCI_PCI_BAR]; |
1933 | u32 ctl; | 1933 | u32 ctl; |
1934 | 1934 | ||
1935 | if (mesg.event == PM_EVENT_SUSPEND) { | 1935 | if (mesg.event & PM_EVENT_SLEEP) { |
1936 | /* AHCI spec rev1.1 section 8.3.3: | 1936 | /* AHCI spec rev1.1 section 8.3.3: |
1937 | * Software must disable interrupts prior to requesting a | 1937 | * Software must disable interrupts prior to requesting a |
1938 | * transition of the HBA to D3 state. | 1938 | * transition of the HBA to D3 state. |
@@ -1975,16 +1975,11 @@ static int ahci_port_start(struct ata_port *ap) | |||
1975 | struct ahci_port_priv *pp; | 1975 | struct ahci_port_priv *pp; |
1976 | void *mem; | 1976 | void *mem; |
1977 | dma_addr_t mem_dma; | 1977 | dma_addr_t mem_dma; |
1978 | int rc; | ||
1979 | 1978 | ||
1980 | pp = devm_kzalloc(dev, sizeof(*pp), GFP_KERNEL); | 1979 | pp = devm_kzalloc(dev, sizeof(*pp), GFP_KERNEL); |
1981 | if (!pp) | 1980 | if (!pp) |
1982 | return -ENOMEM; | 1981 | return -ENOMEM; |
1983 | 1982 | ||
1984 | rc = ata_pad_alloc(ap, dev); | ||
1985 | if (rc) | ||
1986 | return rc; | ||
1987 | |||
1988 | mem = dmam_alloc_coherent(dev, AHCI_PORT_PRIV_DMA_SZ, &mem_dma, | 1983 | mem = dmam_alloc_coherent(dev, AHCI_PORT_PRIV_DMA_SZ, &mem_dma, |
1989 | GFP_KERNEL); | 1984 | GFP_KERNEL); |
1990 | if (!mem) | 1985 | if (!mem) |