aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2018-10-09 10:08:23 -0400
committerBjorn Helgaas <bhelgaas@google.com>2018-10-10 16:46:47 -0400
commita6f44cf9f5cc60471cf06f3d5391fc6041eb37a5 (patch)
tree1b7f35899fde28aa1122e5be820ad887875834ab
parent18b01b16e8bae9cd227909f6e6d2783d74855f65 (diff)
PCI: Remove pci_set_dma_seg_boundary()
The two callers can just use dma_set_seg_boundary() directly. Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
-rw-r--r--drivers/pci/probe.c2
-rw-r--r--drivers/s390/net/ism_drv.c2
-rw-r--r--include/linux/pci-dma-compat.h9
3 files changed, 2 insertions, 11 deletions
diff --git a/drivers/pci/probe.c b/drivers/pci/probe.c
index 7c422ccbf9b4..72dd926680be 100644
--- a/drivers/pci/probe.c
+++ b/drivers/pci/probe.c
@@ -2398,7 +2398,7 @@ void pci_device_add(struct pci_dev *dev, struct pci_bus *bus)
2398 dev->dev.coherent_dma_mask = 0xffffffffull; 2398 dev->dev.coherent_dma_mask = 0xffffffffull;
2399 2399
2400 pci_set_dma_max_seg_size(dev, 65536); 2400 pci_set_dma_max_seg_size(dev, 65536);
2401 pci_set_dma_seg_boundary(dev, 0xffffffff); 2401 dma_set_seg_boundary(&dev->dev, 0xffffffff);
2402 2402
2403 /* Fix up broken headers */ 2403 /* Fix up broken headers */
2404 pci_fixup_device(pci_fixup_header, dev); 2404 pci_fixup_device(pci_fixup_header, dev);
diff --git a/drivers/s390/net/ism_drv.c b/drivers/s390/net/ism_drv.c
index c0631895154e..8688c0fff761 100644
--- a/drivers/s390/net/ism_drv.c
+++ b/drivers/s390/net/ism_drv.c
@@ -515,7 +515,7 @@ static int ism_probe(struct pci_dev *pdev, const struct pci_device_id *id)
515 if (ret) 515 if (ret)
516 goto err_unmap; 516 goto err_unmap;
517 517
518 pci_set_dma_seg_boundary(pdev, SZ_1M - 1); 518 dma_set_seg_boundary(&pdev->dev, SZ_1M - 1);
519 pci_set_dma_max_seg_size(pdev, SZ_1M); 519 pci_set_dma_max_seg_size(pdev, SZ_1M);
520 pci_set_master(pdev); 520 pci_set_master(pdev);
521 521
diff --git a/include/linux/pci-dma-compat.h b/include/linux/pci-dma-compat.h
index c3f1b44ade29..558a109ab497 100644
--- a/include/linux/pci-dma-compat.h
+++ b/include/linux/pci-dma-compat.h
@@ -125,12 +125,6 @@ static inline int pci_set_dma_max_seg_size(struct pci_dev *dev,
125{ 125{
126 return dma_set_max_seg_size(&dev->dev, size); 126 return dma_set_max_seg_size(&dev->dev, size);
127} 127}
128
129static inline int pci_set_dma_seg_boundary(struct pci_dev *dev,
130 unsigned long mask)
131{
132 return dma_set_seg_boundary(&dev->dev, mask);
133}
134#else 128#else
135static inline int pci_set_dma_mask(struct pci_dev *dev, u64 mask) 129static inline int pci_set_dma_mask(struct pci_dev *dev, u64 mask)
136{ return -EIO; } 130{ return -EIO; }
@@ -139,9 +133,6 @@ static inline int pci_set_consistent_dma_mask(struct pci_dev *dev, u64 mask)
139static inline int pci_set_dma_max_seg_size(struct pci_dev *dev, 133static inline int pci_set_dma_max_seg_size(struct pci_dev *dev,
140 unsigned int size) 134 unsigned int size)
141{ return -EIO; } 135{ return -EIO; }
142static inline int pci_set_dma_seg_boundary(struct pci_dev *dev,
143 unsigned long mask)
144{ return -EIO; }
145#endif 136#endif
146 137
147#endif 138#endif