summaryrefslogtreecommitdiffstats
path: root/drivers/pci
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2018-05-03 16:25:08 +0200
committerChristoph Hellwig <hch@lst.de>2018-05-03 16:25:08 +0200
commit3d6ce86ee79465e1b1b6e287f8ea26b553fc768e (patch)
tree5305a5ffefc514d485ae634e9d53b3e601fafbd3 /drivers/pci
parent07397df29e57cde5799af16e8f148ae10ed75285 (diff)
downloadlinux-3d6ce86ee79465e1b1b6e287f8ea26b553fc768e.tar.gz
linux-3d6ce86ee79465e1b1b6e287f8ea26b553fc768e.tar.bz2
linux-3d6ce86ee79465e1b1b6e287f8ea26b553fc768e.zip
drivers: remove force dma flag from buses
With each bus implementing its own DMA configuration callback, there is no need for bus to explicitly set the force_dma flag. Modify the of_dma_configure function to accept an input parameter which specifies if implicit DMA configuration is required when it is not described by the firmware. Signed-off-by: Nipun Gupta <nipun.gupta@nxp.com> Acked-by: Bjorn Helgaas <bhelgaas@google.com> # PCI parts Reviewed-by: Rob Herring <robh@kernel.org> [hch: tweaked the changelog a bit] Signed-off-by: Christoph Hellwig <hch@lst.de>
Diffstat (limited to 'drivers/pci')
-rw-r--r--drivers/pci/pci-driver.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/pci/pci-driver.c b/drivers/pci/pci-driver.c
index ba8c6b46269e..f8269a725667 100644
--- a/drivers/pci/pci-driver.c
+++ b/drivers/pci/pci-driver.c
@@ -1595,7 +1595,7 @@ static int pci_dma_configure(struct device *dev)
if (IS_ENABLED(CONFIG_OF) && bridge->parent &&
bridge->parent->of_node) {
- ret = of_dma_configure(dev, bridge->parent->of_node);
+ ret = of_dma_configure(dev, bridge->parent->of_node, true);
} else if (has_acpi_companion(bridge)) {
struct acpi_device *adev = to_acpi_device_node(bridge->fwnode);
enum dev_dma_attr attr = acpi_get_dma_attr(adev);
@@ -1621,7 +1621,6 @@ struct bus_type pci_bus_type = {
.pm = PCI_PM_OPS_PTR,
.num_vf = pci_bus_num_vf,
.dma_configure = pci_dma_configure,
- .force_dma = true,
};
EXPORT_SYMBOL(pci_bus_type);