Skip to content

Commit 671ec2e

Browse files
Sasha Levingregkh
authored andcommitted
Revert "PCI: qcom: Advertise Hotplug Slot Capability with no Command Completion support"
This reverts commit f176c47. Signed-off-by: Sasha Levin <sashal@kernel.org>
1 parent d844702 commit 671ec2e

1 file changed

Lines changed: 6 additions & 11 deletions

File tree

drivers/pci/controller/dwc/pcie-qcom.c

Lines changed: 6 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -341,20 +341,15 @@ static void qcom_pcie_clear_aspm_l0s(struct dw_pcie *pci)
341341
dw_pcie_dbi_ro_wr_dis(pci);
342342
}
343343

344-
static void qcom_pcie_set_slot_nccs(struct dw_pcie *pci)
344+
static void qcom_pcie_clear_hpc(struct dw_pcie *pci)
345345
{
346346
u16 offset = dw_pcie_find_capability(pci, PCI_CAP_ID_EXP);
347347
u32 val;
348348

349349
dw_pcie_dbi_ro_wr_en(pci);
350350

351-
/*
352-
* Qcom PCIe Root Ports do not support generating command completion
353-
* notifications for the Hot-Plug commands. So set the NCCS field to
354-
* avoid waiting for the completions.
355-
*/
356351
val = readl(pci->dbi_base + offset + PCI_EXP_SLTCAP);
357-
val |= PCI_EXP_SLTCAP_NCCS;
352+
val &= ~PCI_EXP_SLTCAP_HPC;
358353
writel(val, pci->dbi_base + offset + PCI_EXP_SLTCAP);
359354

360355
dw_pcie_dbi_ro_wr_dis(pci);
@@ -554,7 +549,7 @@ static int qcom_pcie_post_init_2_1_0(struct qcom_pcie *pcie)
554549
writel(CFG_BRIDGE_SB_INIT,
555550
pci->dbi_base + AXI_MSTR_RESP_COMP_CTRL1);
556551

557-
qcom_pcie_set_slot_nccs(pcie->pci);
552+
qcom_pcie_clear_hpc(pcie->pci);
558553

559554
return 0;
560555
}
@@ -634,7 +629,7 @@ static int qcom_pcie_post_init_1_0_0(struct qcom_pcie *pcie)
634629
writel(val, pcie->parf + PARF_AXI_MSTR_WR_ADDR_HALT);
635630
}
636631

637-
qcom_pcie_set_slot_nccs(pcie->pci);
632+
qcom_pcie_clear_hpc(pcie->pci);
638633

639634
return 0;
640635
}
@@ -727,7 +722,7 @@ static int qcom_pcie_post_init_2_3_2(struct qcom_pcie *pcie)
727722
val |= EN;
728723
writel(val, pcie->parf + PARF_AXI_MSTR_WR_ADDR_HALT_V2);
729724

730-
qcom_pcie_set_slot_nccs(pcie->pci);
725+
qcom_pcie_clear_hpc(pcie->pci);
731726

732727
return 0;
733728
}
@@ -1033,7 +1028,7 @@ static int qcom_pcie_post_init_2_7_0(struct qcom_pcie *pcie)
10331028
writel(WR_NO_SNOOP_OVERRIDE_EN | RD_NO_SNOOP_OVERRIDE_EN,
10341029
pcie->parf + PARF_NO_SNOOP_OVERRIDE);
10351030

1036-
qcom_pcie_set_slot_nccs(pcie->pci);
1031+
qcom_pcie_clear_hpc(pcie->pci);
10371032

10381033
return 0;
10391034
}

0 commit comments

Comments
 (0)