diff options
author | Serge Semin <Sergey.Semin@baikalelectronics.ru> | 2023-01-13 18:14:08 +0100 |
---|---|---|
committer | Bjorn Helgaas <bhelgaas@google.com> | 2023-02-22 20:46:14 +0100 |
commit | 68373f2c0fd82bc66ec51e2db27ca0fe141210fd (patch) | |
tree | a7c46724dcf0c589e14cdd4d5cabf298128e34cd /drivers/pci/controller/dwc | |
parent | PCI: dwc: Restrict only coherent DMA mask for MSI address allocation (diff) | |
download | linux-68373f2c0fd82bc66ec51e2db27ca0fe141210fd.tar.xz linux-68373f2c0fd82bc66ec51e2db27ca0fe141210fd.zip |
PCI: bt1: Set 64-bit DMA mask
The DW PCIe Root Port IP core is synthesized with the 64-bit AXI address
bus. Since the device is also equipped with the eDMA engine, explicitly
set the device DMA mask so DMA engine clients can allocate data buffers
anywhere in the 64-bit memory space.
Link: https://lore.kernel.org/r/20230113171409.30470-27-Sergey.Semin@baikalelectronics.ru
Signed-off-by: Serge Semin <Sergey.Semin@baikalelectronics.ru>
Signed-off-by: Lorenzo Pieralisi <lpieralisi@kernel.org>
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Diffstat (limited to 'drivers/pci/controller/dwc')
-rw-r--r-- | drivers/pci/controller/dwc/pcie-bt1.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/pci/controller/dwc/pcie-bt1.c b/drivers/pci/controller/dwc/pcie-bt1.c index 3346770e6654..95a723a6fd46 100644 --- a/drivers/pci/controller/dwc/pcie-bt1.c +++ b/drivers/pci/controller/dwc/pcie-bt1.c @@ -583,6 +583,10 @@ static int bt1_pcie_add_port(struct bt1_pcie *btpci) struct device *dev = &btpci->pdev->dev; int ret; + ret = dma_set_mask_and_coherent(dev, DMA_BIT_MASK(64)); + if (ret) + return ret; + btpci->dw.version = DW_PCIE_VER_460A; btpci->dw.dev = dev; btpci->dw.ops = &bt1_pcie_ops; |