summaryrefslogtreecommitdiffstats
path: root/drivers/scsi/ipr.c
diff options
context:
space:
mode:
authorAnton Blanchard <anton@samba.org>2014-10-30 17:27:09 -0500
committerChristoph Hellwig <hch@lst.de>2014-11-12 11:32:00 +0100
commit869404cb4ff23a8f7af09d8395586630ff56f72f (patch)
tree78a68190015cb65db1bbf63fe9808ad2bb53fefc /drivers/scsi/ipr.c
parentd73341bff0c21157ee84dcb619b2ddcd4afc1bb3 (diff)
downloadlinux-869404cb4ff23a8f7af09d8395586630ff56f72f.tar.gz
linux-869404cb4ff23a8f7af09d8395586630ff56f72f.tar.bz2
linux-869404cb4ff23a8f7af09d8395586630ff56f72f.zip
ipr: set coherent DMA mask
Use dma_set_mask_and_coherent() to set both the DMA and coherent DMA mask. Signed-off-by: Anton Blanchard <anton@samba.org> Signed-off-by: Brian King <brking@linux.vnet.ibm.com> Signed-off-by: Christoph Hellwig <hch@lst.de>
Diffstat (limited to 'drivers/scsi/ipr.c')
-rw-r--r--drivers/scsi/ipr.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/drivers/scsi/ipr.c b/drivers/scsi/ipr.c
index d6b3e4617283..d8d16625a876 100644
--- a/drivers/scsi/ipr.c
+++ b/drivers/scsi/ipr.c
@@ -9582,16 +9582,17 @@ static int ipr_probe_ioa(struct pci_dev *pdev,
ipr_init_regs(ioa_cfg);
if (ioa_cfg->sis64) {
- rc = dma_set_mask(&pdev->dev, DMA_BIT_MASK(64));
+ rc = dma_set_mask_and_coherent(&pdev->dev, DMA_BIT_MASK(64));
if (rc < 0) {
- dev_dbg(&pdev->dev, "Failed to set 64 bit PCI DMA mask\n");
- rc = dma_set_mask(&pdev->dev, DMA_BIT_MASK(32));
+ dev_dbg(&pdev->dev, "Failed to set 64 bit DMA mask\n");
+ rc = dma_set_mask_and_coherent(&pdev->dev,
+ DMA_BIT_MASK(32));
}
} else
- rc = dma_set_mask(&pdev->dev, DMA_BIT_MASK(32));
+ rc = dma_set_mask_and_coherent(&pdev->dev, DMA_BIT_MASK(32));
if (rc < 0) {
- dev_err(&pdev->dev, "Failed to set PCI DMA mask\n");
+ dev_err(&pdev->dev, "Failed to set DMA mask\n");
goto cleanup_nomem;
}