summaryrefslogtreecommitdiffstats
path: root/drivers/scsi/aacraid/comminit.c
diff options
context:
space:
mode:
authorMahesh Rajashekhara <mahesh.rajashekhara@microsemi.com>2017-04-05 16:14:16 +0530
committerMartin K. Petersen <martin.petersen@oracle.com>2017-04-26 18:28:06 -0400
commitf481973d5efdb63b7c6ca6b0ecd2b8462556a461 (patch)
treebb254fe9f09a156d6b2768fd006bfc76d2cdb49f /drivers/scsi/aacraid/comminit.c
parent6cf161150d815da0ee8cff158b185bc33dca3a34 (diff)
downloadlinux-f481973d5efdb63b7c6ca6b0ecd2b8462556a461.tar.gz
linux-f481973d5efdb63b7c6ca6b0ecd2b8462556a461.tar.bz2
linux-f481973d5efdb63b7c6ca6b0ecd2b8462556a461.zip
scsi: aacraid: pci_alloc_consistent() failures on ARM64
There were pci_alloc_consistent() failures on ARM64 platform. Use dma_alloc_coherent() with GFP_KERNEL flag DMA memory allocations. Signed-off-by: Mahesh Rajashekhara <mahesh.rajashekhara@microsemi.com> [hch: tweaked indentation, removed memsets] Signed-off-by: Christoph Hellwig <hch@lst.de> Acked-by: Dave Carroll <david.carroll@microsemi.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'drivers/scsi/aacraid/comminit.c')
-rw-r--r--drivers/scsi/aacraid/comminit.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/scsi/aacraid/comminit.c b/drivers/scsi/aacraid/comminit.c
index 35607005f7e1..1151505853cf 100644
--- a/drivers/scsi/aacraid/comminit.c
+++ b/drivers/scsi/aacraid/comminit.c
@@ -99,8 +99,7 @@ static int aac_alloc_comm(struct aac_dev *dev, void **commaddr, unsigned long co
size = fibsize + aac_init_size + commsize + commalign +
printfbufsiz + host_rrq_size;
- base = pci_alloc_consistent(dev->pdev, size, &phys);
-
+ base = dma_alloc_coherent(&dev->pdev->dev, size, &phys, GFP_KERNEL);
if (base == NULL) {
printk(KERN_ERR "aacraid: unable to create mapping.\n");
return 0;