[PATCH 08/11] PCI: qcom-ep: Add Nord PCIe Endpoint controller support
Krishna Chaitanya Chundru
krishna.chundru at oss.qualcomm.com
Sat Nov 21 18:56:21 PST 2026
Add support for the PCIe Endpoint controller found on the Nord platform
via the qcom,nord-pcie-ep compatible. It supports HDMA, overrides the
NO_SNOOP attribute and disables the MHI RAM parity check, and is MSI-X
capable.
The Nord HDMA block spaces its per-channel register blocks 4K apart
instead of the dw-edma 256-byte default, so program edma.ch_space_sz
from the SoC config.
Signed-off-by: Krishna Chaitanya Chundru <krishna.chundru at oss.qualcomm.com>
---
drivers/pci/controller/dwc/pcie-qcom-ep.c | 13 +++++++++++++
1 file changed, 13 insertions(+)
diff --git a/drivers/pci/controller/dwc/pcie-qcom-ep.c b/drivers/pci/controller/dwc/pcie-qcom-ep.c
index c794a2207df2..661bd8aac7cc 100644
--- a/drivers/pci/controller/dwc/pcie-qcom-ep.c
+++ b/drivers/pci/controller/dwc/pcie-qcom-ep.c
@@ -171,6 +171,8 @@ enum qcom_pcie_ep_link_status {
* @disable_mhi_ram_parity_check: Disable MHI RAM data parity error check
* @firmware_managed: Set if the controller is firmware managed
* @msix_capable: Set if the controller supports MSI-X
+ * @ch_space_sz: HDMA per-channel register space size in bytes. 0 selects the
+ * dw-edma default (256).
*/
struct qcom_pcie_ep_cfg {
bool hdma_support;
@@ -178,6 +180,7 @@ struct qcom_pcie_ep_cfg {
bool disable_mhi_ram_parity_check;
bool firmware_managed;
bool msix_capable;
+ u32 ch_space_sz;
};
/**
@@ -903,6 +906,7 @@ static int qcom_pcie_ep_probe(struct platform_device *pdev)
pcie_ep->pci.edma.ll_wr_cnt = 8;
pcie_ep->pci.edma.ll_rd_cnt = 8;
pcie_ep->pci.edma.mf = EDMA_MF_HDMA_NATIVE;
+ pcie_ep->pci.edma.ch_space_sz = pcie_ep->cfg->ch_space_sz;
}
platform_set_drvdata(pdev, pcie_ep);
@@ -984,7 +988,16 @@ static const struct qcom_pcie_ep_cfg cfg_1_34_0_fw_managed = {
.firmware_managed = true,
};
+static const struct qcom_pcie_ep_cfg cfg_nord = {
+ .hdma_support = true,
+ .override_no_snoop = true,
+ .disable_mhi_ram_parity_check = true,
+ .msix_capable = true,
+ .ch_space_sz = SZ_4K,
+};
+
static const struct of_device_id qcom_pcie_ep_match[] = {
+ { .compatible = "qcom,nord-pcie-ep", .data = &cfg_nord},
{ .compatible = "qcom,sa8255p-pcie-ep", .data = &cfg_1_34_0_fw_managed},
{ .compatible = "qcom,sa8775p-pcie-ep", .data = &cfg_1_34_0},
{ .compatible = "qcom,sdx55-pcie-ep", },
--
2.34.1
More information about the linux-phy
mailing list