Skip to content

Commit 5147ba8

Browse files
Krishna chaitanya chundrubjorn-helgaas
authored andcommitted
PCI: qcom: Allow ASPM L1 and substates for 2.7.0
Allow ASPM L1 and its substates. By default this is disabled in the qcom specific hardware. Enable it explicitly only for controllers belonging to 2_7_0. This does not affect any link capability registers; it will allow the link transitions to L1 and its substates only if they are already supported. Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Krishna chaitanya chundru <[email protected]> Signed-off-by: Bjorn Helgaas <[email protected]> Reviewed-by: Manivannan Sadhasivam <[email protected]> Acked-by: Stanimir Varbanov <[email protected]>
1 parent 839fbde commit 5147ba8

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

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

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,9 @@
4141
#define L23_CLK_RMV_DIS BIT(2)
4242
#define L1_CLK_RMV_DIS BIT(1)
4343

44+
#define PCIE20_PARF_PM_CTRL 0x20
45+
#define REQ_NOT_ENTR_L1 BIT(5)
46+
4447
#define PCIE20_PARF_PHY_CTRL 0x40
4548
#define PHY_CTRL_PHY_TX0_TERM_OFFSET_MASK GENMASK(20, 16)
4649
#define PHY_CTRL_PHY_TX0_TERM_OFFSET(x) ((x) << 16)
@@ -1265,6 +1268,11 @@ static int qcom_pcie_init_2_7_0(struct qcom_pcie *pcie)
12651268
val |= BIT(4);
12661269
writel(val, pcie->parf + PCIE20_PARF_MHI_CLOCK_RESET_CTRL);
12671270

1271+
/* Enable L1 and L1SS */
1272+
val = readl(pcie->parf + PCIE20_PARF_PM_CTRL);
1273+
val &= ~REQ_NOT_ENTR_L1;
1274+
writel(val, pcie->parf + PCIE20_PARF_PM_CTRL);
1275+
12681276
if (IS_ENABLED(CONFIG_PCI_MSI)) {
12691277
val = readl(pcie->parf + PCIE20_PARF_AXI_MSTR_WR_ADDR_HALT);
12701278
val |= BIT(31);

0 commit comments

Comments
 (0)