* [PATCH V4 01/22] PCI: tegra194: Use devm_gpiod_get_optional() to parse "nvidia,refclk-select"
2026-01-26 7:44 [PATCH V4 00/22] Enhancements to pcie-tegra194 driver Manikanta Maddireddy
@ 2026-01-26 7:44 ` Manikanta Maddireddy
2026-01-26 7:44 ` [PATCH V4 02/22] PCI: tegra194: Drive CLKREQ signal low explicitly Manikanta Maddireddy
` (22 subsequent siblings)
23 siblings, 0 replies; 33+ messages in thread
From: Manikanta Maddireddy @ 2026-01-26 7:44 UTC (permalink / raw)
To: bhelgaas, lpieralisi, kwilczynski, mani, robh, krzk+dt, conor+dt,
thierry.reding, jonathanh, jingoohan1, vidyas, cassel,
18255117159
Cc: linux-pci, devicetree, linux-tegra, linux-kernel,
Manikanta Maddireddy
From: Vidya Sagar <vidyas@nvidia.com>
The GPIO DT property "nvidia,refclk-select" to select the PCIe reference
clock is optional. Use devm_gpiod_get_optional() to get it.
Signed-off-by: Vidya Sagar <vidyas@nvidia.com>
Signed-off-by: Manikanta Maddireddy <mmaddireddy@nvidia.com>
---
V4:
* None
V3:
* None
V2:
* None
drivers/pci/controller/dwc/pcie-tegra194.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/pci/controller/dwc/pcie-tegra194.c b/drivers/pci/controller/dwc/pcie-tegra194.c
index 0ddeef70726d..f4a13ca2e742 100644
--- a/drivers/pci/controller/dwc/pcie-tegra194.c
+++ b/drivers/pci/controller/dwc/pcie-tegra194.c
@@ -1163,9 +1163,9 @@ static int tegra_pcie_dw_parse_dt(struct tegra_pcie_dw *pcie)
return err;
}
- pcie->pex_refclk_sel_gpiod = devm_gpiod_get(pcie->dev,
- "nvidia,refclk-select",
- GPIOD_OUT_HIGH);
+ pcie->pex_refclk_sel_gpiod = devm_gpiod_get_optional(pcie->dev,
+ "nvidia,refclk-select",
+ GPIOD_OUT_HIGH);
if (IS_ERR(pcie->pex_refclk_sel_gpiod)) {
int err = PTR_ERR(pcie->pex_refclk_sel_gpiod);
const char *level = KERN_ERR;
--
2.34.1
^ permalink raw reply related [flat|nested] 33+ messages in thread* [PATCH V4 02/22] PCI: tegra194: Drive CLKREQ signal low explicitly
2026-01-26 7:44 [PATCH V4 00/22] Enhancements to pcie-tegra194 driver Manikanta Maddireddy
2026-01-26 7:44 ` [PATCH V4 01/22] PCI: tegra194: Use devm_gpiod_get_optional() to parse "nvidia,refclk-select" Manikanta Maddireddy
@ 2026-01-26 7:44 ` Manikanta Maddireddy
2026-01-26 7:45 ` [PATCH V4 03/22] PCI: tegra194: Fix polling delay for L2 state Manikanta Maddireddy
` (21 subsequent siblings)
23 siblings, 0 replies; 33+ messages in thread
From: Manikanta Maddireddy @ 2026-01-26 7:44 UTC (permalink / raw)
To: bhelgaas, lpieralisi, kwilczynski, mani, robh, krzk+dt, conor+dt,
thierry.reding, jonathanh, jingoohan1, vidyas, cassel,
18255117159
Cc: linux-pci, devicetree, linux-tegra, linux-kernel,
Manikanta Maddireddy
From: Vidya Sagar <vidyas@nvidia.com>
Currently, the default setting is that CLKREQ signal of a Root Port
is internally overridden to '0' to enable REFCLK to flow out to the slot.
It is observed that one of the PCIe switches (case in point Broadcom PCIe
Gen4 switch) is propagating the CLKREQ signal of the root port to the
downstream side of the switch and expecting the endpoints to pull it low
so that it (PCIe switch) can give out the REFCLK although the Switch as
such doesn't support CLK-PM or ASPM-L1SS. So, as a workaround, this patch
drives the CLKREQ of the Root Port itself low to avoid link up issues
between PCIe switch downstream port and endpoints. This is not a wrong
thing to do after all the CLKREQ is anyway being overridden to '0'
internally and now it is just that the same is being propagated outside
also.
Signed-off-by: Vidya Sagar <vidyas@nvidia.com>
Signed-off-by: Manikanta Maddireddy <mmaddireddy@nvidia.com>
---
V4:
* None
V3:
* Reworded the commit message
V2:
* None
drivers/pci/controller/dwc/pcie-tegra194.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/pci/controller/dwc/pcie-tegra194.c b/drivers/pci/controller/dwc/pcie-tegra194.c
index f4a13ca2e742..ab2c3f07ed4f 100644
--- a/drivers/pci/controller/dwc/pcie-tegra194.c
+++ b/drivers/pci/controller/dwc/pcie-tegra194.c
@@ -44,6 +44,7 @@
#define APPL_PINMUX_CLKREQ_OVERRIDE BIT(3)
#define APPL_PINMUX_CLK_OUTPUT_IN_OVERRIDE_EN BIT(4)
#define APPL_PINMUX_CLK_OUTPUT_IN_OVERRIDE BIT(5)
+#define APPL_PINMUX_CLKREQ_DEFAULT_VALUE BIT(13)
#define APPL_CTRL 0x4
#define APPL_CTRL_SYS_PRE_DET_STATE BIT(6)
@@ -1454,6 +1455,7 @@ static int tegra_pcie_config_controller(struct tegra_pcie_dw *pcie,
val = appl_readl(pcie, APPL_PINMUX);
val |= APPL_PINMUX_CLKREQ_OVERRIDE_EN;
val &= ~APPL_PINMUX_CLKREQ_OVERRIDE;
+ val &= ~APPL_PINMUX_CLKREQ_DEFAULT_VALUE;
appl_writel(pcie, val, APPL_PINMUX);
}
--
2.34.1
^ permalink raw reply related [flat|nested] 33+ messages in thread* [PATCH V4 03/22] PCI: tegra194: Fix polling delay for L2 state
2026-01-26 7:44 [PATCH V4 00/22] Enhancements to pcie-tegra194 driver Manikanta Maddireddy
2026-01-26 7:44 ` [PATCH V4 01/22] PCI: tegra194: Use devm_gpiod_get_optional() to parse "nvidia,refclk-select" Manikanta Maddireddy
2026-01-26 7:44 ` [PATCH V4 02/22] PCI: tegra194: Drive CLKREQ signal low explicitly Manikanta Maddireddy
@ 2026-01-26 7:45 ` Manikanta Maddireddy
2026-01-26 7:45 ` [PATCH V4 04/22] PCI: tegra194: Apply pinctrl settings for both PCIe RP and EP Manikanta Maddireddy
` (20 subsequent siblings)
23 siblings, 0 replies; 33+ messages in thread
From: Manikanta Maddireddy @ 2026-01-26 7:45 UTC (permalink / raw)
To: bhelgaas, lpieralisi, kwilczynski, mani, robh, krzk+dt, conor+dt,
thierry.reding, jonathanh, jingoohan1, vidyas, cassel,
18255117159
Cc: linux-pci, devicetree, linux-tegra, linux-kernel,
Manikanta Maddireddy
From: Vidya Sagar <vidyas@nvidia.com>
As per PCIe spec r6.0, sec 5.3.3.2.1, after sending PME_Turn_Off message,
Root port should wait for 1~10 msec for PME_TO_Ack message. Currently,
driver is polling for 10 msec with 1 usec delay which is aggressive.
Change it to 10 msec polling with 100 usec delay. Since this function
is used in non-atomic context only, use non-atomic poll function.
Fixes: 56e15a238d92 ("PCI: tegra: Add Tegra194 PCIe support")
Signed-off-by: Vidya Sagar <vidyas@nvidia.com>
Signed-off-by: Manikanta Maddireddy <mmaddireddy@nvidia.com>
---
V4:
* None
V3:
* Changed atomic call to non-atomic call
* Reworded the commit message
V2:
* None
drivers/pci/controller/dwc/pcie-tegra194.c | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
diff --git a/drivers/pci/controller/dwc/pcie-tegra194.c b/drivers/pci/controller/dwc/pcie-tegra194.c
index ab2c3f07ed4f..0b8c1a7ca232 100644
--- a/drivers/pci/controller/dwc/pcie-tegra194.c
+++ b/drivers/pci/controller/dwc/pcie-tegra194.c
@@ -199,7 +199,8 @@
#define CAP_SPCIE_CAP_OFF_USP_TX_PRESET0_MASK GENMASK(11, 8)
#define CAP_SPCIE_CAP_OFF_USP_TX_PRESET0_SHIFT 8
-#define PME_ACK_TIMEOUT 10000
+#define PME_ACK_DELAY 100 /* 100 us */
+#define PME_ACK_TIMEOUT 10000 /* 10 ms */
#define LTSSM_TIMEOUT 50000 /* 50ms */
@@ -1555,9 +1556,9 @@ static int tegra_pcie_try_link_l2(struct tegra_pcie_dw *pcie)
val |= APPL_PM_XMT_TURNOFF_STATE;
appl_writel(pcie, val, APPL_RADM_STATUS);
- return readl_poll_timeout_atomic(pcie->appl_base + APPL_DEBUG, val,
- val & APPL_DEBUG_PM_LINKST_IN_L2_LAT,
- 1, PME_ACK_TIMEOUT);
+ return readl_poll_timeout(pcie->appl_base + APPL_DEBUG, val,
+ val & APPL_DEBUG_PM_LINKST_IN_L2_LAT,
+ PME_ACK_DELAY, PME_ACK_TIMEOUT);
}
static void tegra_pcie_dw_pme_turnoff(struct tegra_pcie_dw *pcie)
--
2.34.1
^ permalink raw reply related [flat|nested] 33+ messages in thread* [PATCH V4 04/22] PCI: tegra194: Apply pinctrl settings for both PCIe RP and EP
2026-01-26 7:44 [PATCH V4 00/22] Enhancements to pcie-tegra194 driver Manikanta Maddireddy
` (2 preceding siblings ...)
2026-01-26 7:45 ` [PATCH V4 03/22] PCI: tegra194: Fix polling delay for L2 state Manikanta Maddireddy
@ 2026-01-26 7:45 ` Manikanta Maddireddy
2026-01-30 17:21 ` Jon Hunter
2026-01-26 7:45 ` [PATCH V4 05/22] PCI: tegra194: Refactor LTSSM state polling on surprise down Manikanta Maddireddy
` (19 subsequent siblings)
23 siblings, 1 reply; 33+ messages in thread
From: Manikanta Maddireddy @ 2026-01-26 7:45 UTC (permalink / raw)
To: bhelgaas, lpieralisi, kwilczynski, mani, robh, krzk+dt, conor+dt,
thierry.reding, jonathanh, jingoohan1, vidyas, cassel,
18255117159
Cc: linux-pci, devicetree, linux-tegra, linux-kernel,
Manikanta Maddireddy
From: Vidya Sagar <vidyas@nvidia.com>
PERST# and CLKREQ# pinctrl settings should be applied for both root port
and endpoint mode. Move pinctrl_pm_select_default_state() function call
from root port specific configuration function to probe().
Signed-off-by: Vidya Sagar <vidyas@nvidia.com>
Signed-off-by: Manikanta Maddireddy <mmaddireddy@nvidia.com>
---
V4:
* None
V3:
* None
V2:
* None
drivers/pci/controller/dwc/pcie-tegra194.c | 19 +++++++++++++------
1 file changed, 13 insertions(+), 6 deletions(-)
diff --git a/drivers/pci/controller/dwc/pcie-tegra194.c b/drivers/pci/controller/dwc/pcie-tegra194.c
index 0b8c1a7ca232..04ff211deaea 100644
--- a/drivers/pci/controller/dwc/pcie-tegra194.c
+++ b/drivers/pci/controller/dwc/pcie-tegra194.c
@@ -1645,12 +1645,6 @@ static int tegra_pcie_config_rp(struct tegra_pcie_dw *pcie)
goto fail_pm_get_sync;
}
- ret = pinctrl_pm_select_default_state(dev);
- if (ret < 0) {
- dev_err(dev, "Failed to configure sideband pins: %d\n", ret);
- goto fail_pm_get_sync;
- }
-
ret = tegra_pcie_init_controller(pcie);
if (ret < 0) {
dev_err(dev, "Failed to initialize controller: %d\n", ret);
@@ -2106,6 +2100,19 @@ static int tegra_pcie_dw_probe(struct platform_device *pdev)
pp = &pci->pp;
pp->num_vectors = MAX_MSI_IRQS;
+ ret = pinctrl_pm_select_default_state(dev);
+ if (ret < 0) {
+ const char *level = KERN_ERR;
+
+ if (ret == -EPROBE_DEFER)
+ level = KERN_DEBUG;
+
+ dev_printk(level, dev,
+ "Failed to configure sideband pins: %d\n",
+ ret);
+ return ret;
+ }
+
ret = tegra_pcie_dw_parse_dt(pcie);
if (ret < 0) {
const char *level = KERN_ERR;
--
2.34.1
^ permalink raw reply related [flat|nested] 33+ messages in thread* Re: [PATCH V4 04/22] PCI: tegra194: Apply pinctrl settings for both PCIe RP and EP
2026-01-26 7:45 ` [PATCH V4 04/22] PCI: tegra194: Apply pinctrl settings for both PCIe RP and EP Manikanta Maddireddy
@ 2026-01-30 17:21 ` Jon Hunter
2026-02-02 5:22 ` Manikanta Maddireddy
0 siblings, 1 reply; 33+ messages in thread
From: Jon Hunter @ 2026-01-30 17:21 UTC (permalink / raw)
To: Manikanta Maddireddy, bhelgaas, lpieralisi, kwilczynski, mani,
robh, krzk+dt, conor+dt, thierry.reding, jingoohan1, vidyas,
cassel, 18255117159
Cc: linux-pci, devicetree, linux-tegra, linux-kernel
On 26/01/2026 07:45, Manikanta Maddireddy wrote:
> From: Vidya Sagar <vidyas@nvidia.com>
>
> PERST# and CLKREQ# pinctrl settings should be applied for both root port
> and endpoint mode. Move pinctrl_pm_select_default_state() function call
> from root port specific configuration function to probe().
>
> Signed-off-by: Vidya Sagar <vidyas@nvidia.com>
> Signed-off-by: Manikanta Maddireddy <mmaddireddy@nvidia.com>
> ---
> V4:
> * None
>
> V3:
> * None
>
> V2:
> * None
>
> drivers/pci/controller/dwc/pcie-tegra194.c | 19 +++++++++++++------
> 1 file changed, 13 insertions(+), 6 deletions(-)
>
> diff --git a/drivers/pci/controller/dwc/pcie-tegra194.c b/drivers/pci/controller/dwc/pcie-tegra194.c
> index 0b8c1a7ca232..04ff211deaea 100644
> --- a/drivers/pci/controller/dwc/pcie-tegra194.c
> +++ b/drivers/pci/controller/dwc/pcie-tegra194.c
> @@ -1645,12 +1645,6 @@ static int tegra_pcie_config_rp(struct tegra_pcie_dw *pcie)
> goto fail_pm_get_sync;
> }
>
> - ret = pinctrl_pm_select_default_state(dev);
> - if (ret < 0) {
> - dev_err(dev, "Failed to configure sideband pins: %d\n", ret);
> - goto fail_pm_get_sync;
> - }
> -
> ret = tegra_pcie_init_controller(pcie);
> if (ret < 0) {
> dev_err(dev, "Failed to initialize controller: %d\n", ret);
> @@ -2106,6 +2100,19 @@ static int tegra_pcie_dw_probe(struct platform_device *pdev)
> pp = &pci->pp;
> pp->num_vectors = MAX_MSI_IRQS;
>
> + ret = pinctrl_pm_select_default_state(dev);
> + if (ret < 0) {
> + const char *level = KERN_ERR;
> +
> + if (ret == -EPROBE_DEFER)
> + level = KERN_DEBUG;
> +
> + dev_printk(level, dev,
> + "Failed to configure sideband pins: %d\n",
> + ret);
We can now use dev_err_probe() to handle the above and this becomes ...
if (ret < 0)
return dev_err_probe(dev, ret, "Failed to configure sideband pins: %d\n", ret);
> + return ret;
> + }
> +
> ret = tegra_pcie_dw_parse_dt(pcie);
> if (ret < 0) {
> const char *level = KERN_ERR;
--
nvpublic
^ permalink raw reply [flat|nested] 33+ messages in thread* Re: [PATCH V4 04/22] PCI: tegra194: Apply pinctrl settings for both PCIe RP and EP
2026-01-30 17:21 ` Jon Hunter
@ 2026-02-02 5:22 ` Manikanta Maddireddy
0 siblings, 0 replies; 33+ messages in thread
From: Manikanta Maddireddy @ 2026-02-02 5:22 UTC (permalink / raw)
To: Jon Hunter
Cc: linux-pci, devicetree, linux-tegra, linux-kernel, 18255117159,
cassel, vidyas, jingoohan1, thierry.reding, conor+dt, krzk+dt,
robh, mani, kwilczynski, lpieralisi, bhelgaas
On 30/01/26 10:51 pm, Jon Hunter wrote:
>
>
> On 26/01/2026 07:45, Manikanta Maddireddy wrote:
>> From: Vidya Sagar <vidyas@nvidia.com>
>>
>> PERST# and CLKREQ# pinctrl settings should be applied for both root port
>> and endpoint mode. Move pinctrl_pm_select_default_state() function call
>> from root port specific configuration function to probe().
>>
>> Signed-off-by: Vidya Sagar <vidyas@nvidia.com>
>> Signed-off-by: Manikanta Maddireddy <mmaddireddy@nvidia.com>
>> ---
>> V4:
>> * None
>>
>> V3:
>> * None
>>
>> V2:
>> * None
>>
>> drivers/pci/controller/dwc/pcie-tegra194.c | 19 +++++++++++++------
>> 1 file changed, 13 insertions(+), 6 deletions(-)
>>
>> diff --git a/drivers/pci/controller/dwc/pcie-tegra194.c
>> b/drivers/pci/controller/dwc/pcie-tegra194.c
>> index 0b8c1a7ca232..04ff211deaea 100644
>> --- a/drivers/pci/controller/dwc/pcie-tegra194.c
>> +++ b/drivers/pci/controller/dwc/pcie-tegra194.c
>> @@ -1645,12 +1645,6 @@ static int tegra_pcie_config_rp(struct
>> tegra_pcie_dw *pcie)
>> goto fail_pm_get_sync;
>> }
>> - ret = pinctrl_pm_select_default_state(dev);
>> - if (ret < 0) {
>> - dev_err(dev, "Failed to configure sideband pins: %d\n", ret);
>> - goto fail_pm_get_sync;
>> - }
>> -
>> ret = tegra_pcie_init_controller(pcie);
>> if (ret < 0) {
>> dev_err(dev, "Failed to initialize controller: %d\n", ret);
>> @@ -2106,6 +2100,19 @@ static int tegra_pcie_dw_probe(struct
>> platform_device *pdev)
>> pp = &pci->pp;
>> pp->num_vectors = MAX_MSI_IRQS;
>> + ret = pinctrl_pm_select_default_state(dev);
>> + if (ret < 0) {
>> + const char *level = KERN_ERR;
>> +
>> + if (ret == -EPROBE_DEFER)
>> + level = KERN_DEBUG;
>> +
>> + dev_printk(level, dev,
>> + "Failed to configure sideband pins: %d\n",
>> + ret);
>
> We can now use dev_err_probe() to handle the above and this becomes ...
>
> if (ret < 0)
> return dev_err_probe(dev, ret, "Failed to configure sideband
> pins: %d\n", ret);
>
Thank you for quick review. I will fix it in next version.
I will wait for few more days for others to review this series and then
send new version.
>> + return ret;
>> + }
>> +
>> ret = tegra_pcie_dw_parse_dt(pcie);
>> if (ret < 0) {
>> const char *level = KERN_ERR;
>
^ permalink raw reply [flat|nested] 33+ messages in thread
* [PATCH V4 05/22] PCI: tegra194: Refactor LTSSM state polling on surprise down
2026-01-26 7:44 [PATCH V4 00/22] Enhancements to pcie-tegra194 driver Manikanta Maddireddy
` (3 preceding siblings ...)
2026-01-26 7:45 ` [PATCH V4 04/22] PCI: tegra194: Apply pinctrl settings for both PCIe RP and EP Manikanta Maddireddy
@ 2026-01-26 7:45 ` Manikanta Maddireddy
2026-01-26 7:45 ` [PATCH V4 06/22] PCI: tegra194: Disable direct speed change for EP Manikanta Maddireddy
` (18 subsequent siblings)
23 siblings, 0 replies; 33+ messages in thread
From: Manikanta Maddireddy @ 2026-01-26 7:45 UTC (permalink / raw)
To: bhelgaas, lpieralisi, kwilczynski, mani, robh, krzk+dt, conor+dt,
thierry.reding, jonathanh, jingoohan1, vidyas, cassel,
18255117159
Cc: linux-pci, devicetree, linux-tegra, linux-kernel,
Manikanta Maddireddy
From: Vidya Sagar <vidyas@nvidia.com>
On surprise down, LTSSM state transits from L0 -> Recovery.RcvrLock ->
Recovery.RcvrSpeed -> Gen1 Recovery.RcvrLock -> Detect. Recovery.RcvrLock
and Recovery.RcvrSpeed transit times are 24 msec and 48 msec respectively.
So, the total time taken to transit from L0 to detect state is ~96 msec.
Hence, increase the poll time to 120 msec.
Disable the LTSSM state after it transits to detect to avoid LTSSM
toggling between polling and detect states.
tegra_pcie_dw_pme_turnoff() function is called in non-atomic context
only, so use the non-atomic poll function.
Signed-off-by: Vidya Sagar <vidyas@nvidia.com>
Signed-off-by: Manikanta Maddireddy <mmaddireddy@nvidia.com>
---
V4:
* None
V3:
* Addressed review comments from Bjorn
* Reworded the commit message
V2:
* None
drivers/pci/controller/dwc/pcie-tegra194.c | 55 +++++++++++++---------
1 file changed, 32 insertions(+), 23 deletions(-)
diff --git a/drivers/pci/controller/dwc/pcie-tegra194.c b/drivers/pci/controller/dwc/pcie-tegra194.c
index 04ff211deaea..d3d577d5f67b 100644
--- a/drivers/pci/controller/dwc/pcie-tegra194.c
+++ b/drivers/pci/controller/dwc/pcie-tegra194.c
@@ -138,7 +138,11 @@
#define APPL_DEBUG_PM_LINKST_IN_L0 0x11
#define APPL_DEBUG_LTSSM_STATE_MASK GENMASK(8, 3)
#define APPL_DEBUG_LTSSM_STATE_SHIFT 3
-#define LTSSM_STATE_PRE_DETECT 5
+#define LTSSM_STATE_DETECT_QUIET 0x00
+#define LTSSM_STATE_DETECT_ACT 0x08
+#define LTSSM_STATE_PRE_DETECT_QUIET 0x28
+#define LTSSM_STATE_DETECT_WAIT 0x30
+#define LTSSM_STATE_L2_IDLE 0xa8
#define APPL_RADM_STATUS 0xE4
#define APPL_PM_XMT_TURNOFF_STATE BIT(0)
@@ -202,7 +206,8 @@
#define PME_ACK_DELAY 100 /* 100 us */
#define PME_ACK_TIMEOUT 10000 /* 10 ms */
-#define LTSSM_TIMEOUT 50000 /* 50ms */
+#define LTSSM_DELAY 10000 /* 10 ms */
+#define LTSSM_TIMEOUT 120000 /* 120 ms */
#define GEN3_GEN4_EQ_PRESET_INIT 5
@@ -1593,23 +1598,22 @@ static void tegra_pcie_dw_pme_turnoff(struct tegra_pcie_dw *pcie)
data &= ~APPL_PINMUX_PEX_RST;
appl_writel(pcie, data, APPL_PINMUX);
+ err = readl_poll_timeout(pcie->appl_base + APPL_DEBUG, data,
+ ((data & APPL_DEBUG_LTSSM_STATE_MASK) == LTSSM_STATE_DETECT_QUIET) ||
+ ((data & APPL_DEBUG_LTSSM_STATE_MASK) == LTSSM_STATE_DETECT_ACT) ||
+ ((data & APPL_DEBUG_LTSSM_STATE_MASK) == LTSSM_STATE_PRE_DETECT_QUIET) ||
+ ((data & APPL_DEBUG_LTSSM_STATE_MASK) == LTSSM_STATE_DETECT_WAIT),
+ LTSSM_DELAY, LTSSM_TIMEOUT);
+ if (err)
+ dev_info(pcie->dev, "Link didn't go to detect state\n");
+
/*
- * Some cards do not go to detect state even after de-asserting
- * PERST#. So, de-assert LTSSM to bring link to detect state.
+ * Deassert LTSSM state to stop the state toggling between
+ * polling and detect.
*/
data = readl(pcie->appl_base + APPL_CTRL);
data &= ~APPL_CTRL_LTSSM_EN;
writel(data, pcie->appl_base + APPL_CTRL);
-
- err = readl_poll_timeout_atomic(pcie->appl_base + APPL_DEBUG,
- data,
- ((data &
- APPL_DEBUG_LTSSM_STATE_MASK) >>
- APPL_DEBUG_LTSSM_STATE_SHIFT) ==
- LTSSM_STATE_PRE_DETECT,
- 1, LTSSM_TIMEOUT);
- if (err)
- dev_info(pcie->dev, "Link didn't go to detect state\n");
}
/*
* DBI registers may not be accessible after this as PLL-E would be
@@ -1677,19 +1681,24 @@ static void pex_ep_event_pex_rst_assert(struct tegra_pcie_dw *pcie)
if (pcie->ep_state == EP_STATE_DISABLED)
return;
- /* Disable LTSSM */
+ ret = readl_poll_timeout(pcie->appl_base + APPL_DEBUG, val,
+ ((val & APPL_DEBUG_LTSSM_STATE_MASK) == LTSSM_STATE_DETECT_QUIET) ||
+ ((val & APPL_DEBUG_LTSSM_STATE_MASK) == LTSSM_STATE_DETECT_ACT) ||
+ ((val & APPL_DEBUG_LTSSM_STATE_MASK) == LTSSM_STATE_PRE_DETECT_QUIET) ||
+ ((val & APPL_DEBUG_LTSSM_STATE_MASK) == LTSSM_STATE_DETECT_WAIT) ||
+ ((val & APPL_DEBUG_LTSSM_STATE_MASK) == LTSSM_STATE_L2_IDLE),
+ LTSSM_DELAY, LTSSM_TIMEOUT);
+ if (ret)
+ dev_err(pcie->dev, "LTSSM state: 0x%x timeout: %d\n", val, ret);
+
+ /*
+ * Deassert LTSSM state to stop the state toggling between
+ * polling and detect.
+ */
val = appl_readl(pcie, APPL_CTRL);
val &= ~APPL_CTRL_LTSSM_EN;
appl_writel(pcie, val, APPL_CTRL);
- ret = readl_poll_timeout(pcie->appl_base + APPL_DEBUG, val,
- ((val & APPL_DEBUG_LTSSM_STATE_MASK) >>
- APPL_DEBUG_LTSSM_STATE_SHIFT) ==
- LTSSM_STATE_PRE_DETECT,
- 1, LTSSM_TIMEOUT);
- if (ret)
- dev_err(pcie->dev, "Failed to go Detect state: %d\n", ret);
-
reset_control_assert(pcie->core_rst);
tegra_pcie_disable_phy(pcie);
--
2.34.1
^ permalink raw reply related [flat|nested] 33+ messages in thread* [PATCH V4 06/22] PCI: tegra194: Disable direct speed change for EP
2026-01-26 7:44 [PATCH V4 00/22] Enhancements to pcie-tegra194 driver Manikanta Maddireddy
` (4 preceding siblings ...)
2026-01-26 7:45 ` [PATCH V4 05/22] PCI: tegra194: Refactor LTSSM state polling on surprise down Manikanta Maddireddy
@ 2026-01-26 7:45 ` Manikanta Maddireddy
2026-01-26 7:45 ` [PATCH V4 07/22] PCI: tegra194: Calibrate P2U for endpoint mode Manikanta Maddireddy
` (17 subsequent siblings)
23 siblings, 0 replies; 33+ messages in thread
From: Manikanta Maddireddy @ 2026-01-26 7:45 UTC (permalink / raw)
To: bhelgaas, lpieralisi, kwilczynski, mani, robh, krzk+dt, conor+dt,
thierry.reding, jonathanh, jingoohan1, vidyas, cassel,
18255117159
Cc: linux-pci, devicetree, linux-tegra, linux-kernel,
Manikanta Maddireddy
From: Vidya Sagar <vidyas@nvidia.com>
Disable direct speed change for the endpoint to prevent it from initiating
the speed change post physical layer link up at gen1. This leaves the speed
change ownership with the host.
Signed-off-by: Vidya Sagar <vidyas@nvidia.com>
Signed-off-by: Manikanta Maddireddy <mmaddireddy@nvidia.com>
---
V4:
* None
V3:
* Reworded the commit message
V2:
* None
drivers/pci/controller/dwc/pcie-tegra194.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/drivers/pci/controller/dwc/pcie-tegra194.c b/drivers/pci/controller/dwc/pcie-tegra194.c
index d3d577d5f67b..25f933a578ae 100644
--- a/drivers/pci/controller/dwc/pcie-tegra194.c
+++ b/drivers/pci/controller/dwc/pcie-tegra194.c
@@ -1841,6 +1841,10 @@ static void pex_ep_event_pex_rst_deassert(struct tegra_pcie_dw *pcie)
reset_control_deassert(pcie->core_rst);
+ val = dw_pcie_readl_dbi(pci, PCIE_LINK_WIDTH_SPEED_CONTROL);
+ val &= ~PORT_LOGIC_SPEED_CHANGE;
+ dw_pcie_writel_dbi(pci, PCIE_LINK_WIDTH_SPEED_CONTROL, val);
+
if (pcie->update_fc_fixup) {
val = dw_pcie_readl_dbi(pci, CFG_TIMER_CTRL_MAX_FUNC_NUM_OFF);
val |= 0x1 << CFG_TIMER_CTRL_ACK_NAK_SHIFT;
--
2.34.1
^ permalink raw reply related [flat|nested] 33+ messages in thread* [PATCH V4 07/22] PCI: tegra194: Calibrate P2U for endpoint mode
2026-01-26 7:44 [PATCH V4 00/22] Enhancements to pcie-tegra194 driver Manikanta Maddireddy
` (5 preceding siblings ...)
2026-01-26 7:45 ` [PATCH V4 06/22] PCI: tegra194: Disable direct speed change for EP Manikanta Maddireddy
@ 2026-01-26 7:45 ` Manikanta Maddireddy
2026-01-26 7:45 ` [PATCH V4 08/22] PCI: tegra194: Free resources during controller deinitialization Manikanta Maddireddy
` (16 subsequent siblings)
23 siblings, 0 replies; 33+ messages in thread
From: Manikanta Maddireddy @ 2026-01-26 7:45 UTC (permalink / raw)
To: bhelgaas, lpieralisi, kwilczynski, mani, robh, krzk+dt, conor+dt,
thierry.reding, jonathanh, jingoohan1, vidyas, cassel,
18255117159
Cc: linux-pci, devicetree, linux-tegra, linux-kernel,
Manikanta Maddireddy
From: Vidya Sagar <vidyas@nvidia.com>
Calibrate P2U for endpoint controller to request UPHY PLL rate change to
Gen1 during initialization. This helps to reset stale PLL state from the
previous bad link state.
Signed-off-by: Vidya Sagar <vidyas@nvidia.com>
Signed-off-by: Manikanta Maddireddy <mmaddireddy@nvidia.com>
---
V4:
* None
V3:
* Reworded the commit message
V2:
* None
drivers/pci/controller/dwc/pcie-tegra194.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/pci/controller/dwc/pcie-tegra194.c b/drivers/pci/controller/dwc/pcie-tegra194.c
index 25f933a578ae..f69bc416b031 100644
--- a/drivers/pci/controller/dwc/pcie-tegra194.c
+++ b/drivers/pci/controller/dwc/pcie-tegra194.c
@@ -1065,6 +1065,9 @@ static int tegra_pcie_enable_phy(struct tegra_pcie_dw *pcie)
ret = phy_power_on(pcie->phys[i]);
if (ret < 0)
goto phy_exit;
+
+ if (pcie->of_data->mode == DW_PCIE_EP_TYPE)
+ phy_calibrate(pcie->phys[i]);
}
return 0;
--
2.34.1
^ permalink raw reply related [flat|nested] 33+ messages in thread* [PATCH V4 08/22] PCI: tegra194: Free resources during controller deinitialization
2026-01-26 7:44 [PATCH V4 00/22] Enhancements to pcie-tegra194 driver Manikanta Maddireddy
` (6 preceding siblings ...)
2026-01-26 7:45 ` [PATCH V4 07/22] PCI: tegra194: Calibrate P2U for endpoint mode Manikanta Maddireddy
@ 2026-01-26 7:45 ` Manikanta Maddireddy
2026-01-26 7:45 ` [PATCH V4 09/22] PCI: tegra194: Remove IRQF_ONESHOT flag during Endpoint interrupt registration Manikanta Maddireddy
` (15 subsequent siblings)
23 siblings, 0 replies; 33+ messages in thread
From: Manikanta Maddireddy @ 2026-01-26 7:45 UTC (permalink / raw)
To: bhelgaas, lpieralisi, kwilczynski, mani, robh, krzk+dt, conor+dt,
thierry.reding, jonathanh, jingoohan1, vidyas, cassel,
18255117159
Cc: linux-pci, devicetree, linux-tegra, linux-kernel,
Manikanta Maddireddy
From: Vidya Sagar <vidyas@nvidia.com>
Call dw_pcie_ep_deinit() during controller deinitialization to free the
resources allocated in common DesignWare driver.
Signed-off-by: Vidya Sagar <vidyas@nvidia.com>
Signed-off-by: Manikanta Maddireddy <mmaddireddy@nvidia.com>
---
V4:
* None
V3:
* This is a new patch in this series
drivers/pci/controller/dwc/pcie-tegra194.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/drivers/pci/controller/dwc/pcie-tegra194.c b/drivers/pci/controller/dwc/pcie-tegra194.c
index f69bc416b031..40f9e1ab03c1 100644
--- a/drivers/pci/controller/dwc/pcie-tegra194.c
+++ b/drivers/pci/controller/dwc/pcie-tegra194.c
@@ -1678,12 +1678,16 @@ static int tegra_pcie_config_rp(struct tegra_pcie_dw *pcie)
static void pex_ep_event_pex_rst_assert(struct tegra_pcie_dw *pcie)
{
+ struct dw_pcie *pci = &pcie->pci;
+ struct dw_pcie_ep *ep = &pci->ep;
u32 val;
int ret;
if (pcie->ep_state == EP_STATE_DISABLED)
return;
+ pci_epc_deinit_notify(ep->epc);
+
ret = readl_poll_timeout(pcie->appl_base + APPL_DEBUG, val,
((val & APPL_DEBUG_LTSSM_STATE_MASK) == LTSSM_STATE_DETECT_QUIET) ||
((val & APPL_DEBUG_LTSSM_STATE_MASK) == LTSSM_STATE_DETECT_ACT) ||
--
2.34.1
^ permalink raw reply related [flat|nested] 33+ messages in thread* [PATCH V4 09/22] PCI: tegra194: Remove IRQF_ONESHOT flag during Endpoint interrupt registration
2026-01-26 7:44 [PATCH V4 00/22] Enhancements to pcie-tegra194 driver Manikanta Maddireddy
` (7 preceding siblings ...)
2026-01-26 7:45 ` [PATCH V4 08/22] PCI: tegra194: Free resources during controller deinitialization Manikanta Maddireddy
@ 2026-01-26 7:45 ` Manikanta Maddireddy
2026-01-26 7:45 ` [PATCH V4 10/22] PCI: tegra194: Enable DMA interrupt Manikanta Maddireddy
` (14 subsequent siblings)
23 siblings, 0 replies; 33+ messages in thread
From: Manikanta Maddireddy @ 2026-01-26 7:45 UTC (permalink / raw)
To: bhelgaas, lpieralisi, kwilczynski, mani, robh, krzk+dt, conor+dt,
thierry.reding, jonathanh, jingoohan1, vidyas, cassel,
18255117159
Cc: linux-pci, devicetree, linux-tegra, linux-kernel,
Manikanta Maddireddy
From: Vidya Sagar <vidyas@nvidia.com>
The Tegra PCIe Endpoint controller has a single interrupt line that is
shared between multiple interrupt sources:
1. PCIe link state events (link up, hot reset done)
2. Configuration space events (Bus Master Enable changes)
3. DMA completion events
Currently, the interrupt is registered with IRQF_ONESHOT, which keeps the
interrupt line masked until the threaded handler completes. This prevents
the DMA driver from sharing the same interrupt line, as the DMA completion
interrupts would be blocked while the threaded handler processes link state
events.
Removing IRQF_ONESHOT is safe for the following reasons:
1. The hard IRQ handler (tegra_pcie_ep_hard_irq) properly acknowledges and
clears all interrupt status bits in hardware before returning. This
prevents interrupt storms and ensures the interrupt controller can
re-enable the interrupt line immediately.
2. The hard IRQ handler explicitly checks for DMA interrupts
(APPL_INTR_STATUS_L1_8_0_EDMA_INT_MASK) and marks them as handled,
allowing the DMA driver's handler to process them separately.
3. The threaded handler (tegra_pcie_ep_irq_thread) only processes link-up
notifications and LTR message sending. These operations don't conflict
with DMA interrupt processing and don't require the interrupt line to
remain masked.
This change enables the DMA driver to share the interrupt line with the
PCIe endpoint driver, allowing both drivers to process their respective
events without blocking each other.
Signed-off-by: Vidya Sagar <vidyas@nvidia.com>
Signed-off-by: Manikanta Maddireddy <mmaddireddy@nvidia.com>
---
V4:
* Add more context to commit message.
V3:
* This is a new patch in this series
drivers/pci/controller/dwc/pcie-tegra194.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/pci/controller/dwc/pcie-tegra194.c b/drivers/pci/controller/dwc/pcie-tegra194.c
index 40f9e1ab03c1..58f33e7bd5a8 100644
--- a/drivers/pci/controller/dwc/pcie-tegra194.c
+++ b/drivers/pci/controller/dwc/pcie-tegra194.c
@@ -2277,7 +2277,7 @@ static int tegra_pcie_dw_probe(struct platform_device *pdev)
ret = devm_request_threaded_irq(dev, pp->irq,
tegra_pcie_ep_hard_irq,
tegra_pcie_ep_irq_thread,
- IRQF_SHARED | IRQF_ONESHOT,
+ IRQF_SHARED,
"tegra-pcie-ep-intr", pcie);
if (ret) {
dev_err(dev, "Failed to request IRQ %d: %d\n", pp->irq,
--
2.34.1
^ permalink raw reply related [flat|nested] 33+ messages in thread* [PATCH V4 10/22] PCI: tegra194: Enable DMA interrupt
2026-01-26 7:44 [PATCH V4 00/22] Enhancements to pcie-tegra194 driver Manikanta Maddireddy
` (8 preceding siblings ...)
2026-01-26 7:45 ` [PATCH V4 09/22] PCI: tegra194: Remove IRQF_ONESHOT flag during Endpoint interrupt registration Manikanta Maddireddy
@ 2026-01-26 7:45 ` Manikanta Maddireddy
2026-01-26 7:45 ` [PATCH V4 11/22] PCI: tegra194: Enable hardware hot reset mode in Endpoint Manikanta Maddireddy
` (13 subsequent siblings)
23 siblings, 0 replies; 33+ messages in thread
From: Manikanta Maddireddy @ 2026-01-26 7:45 UTC (permalink / raw)
To: bhelgaas, lpieralisi, kwilczynski, mani, robh, krzk+dt, conor+dt,
thierry.reding, jonathanh, jingoohan1, vidyas, cassel,
18255117159
Cc: linux-pci, devicetree, linux-tegra, linux-kernel,
Manikanta Maddireddy
From: Vidya Sagar <vidyas@nvidia.com>
Enable DMA interrupt to support Tegra PCIe DMA in both Root port and
Endpoint modes.
Signed-off-by: Vidya Sagar <vidyas@nvidia.com>
Signed-off-by: Manikanta Maddireddy <mmaddireddy@nvidia.com>
---
V4:
* None
V3:
* This is a new patch in this series
drivers/pci/controller/dwc/pcie-tegra194.c | 14 ++++++++++++++
1 file changed, 14 insertions(+)
diff --git a/drivers/pci/controller/dwc/pcie-tegra194.c b/drivers/pci/controller/dwc/pcie-tegra194.c
index 58f33e7bd5a8..e5168754b92d 100644
--- a/drivers/pci/controller/dwc/pcie-tegra194.c
+++ b/drivers/pci/controller/dwc/pcie-tegra194.c
@@ -91,6 +91,7 @@
#define APPL_INTR_EN_L1_8_0 0x44
#define APPL_INTR_EN_L1_8_BW_MGT_INT_EN BIT(2)
#define APPL_INTR_EN_L1_8_AUTO_BW_INT_EN BIT(3)
+#define APPL_INTR_EN_L1_8_EDMA_INT_EN BIT(6)
#define APPL_INTR_EN_L1_8_INTX_EN BIT(11)
#define APPL_INTR_EN_L1_8_AER_INT_EN BIT(15)
@@ -555,6 +556,13 @@ static irqreturn_t tegra_pcie_ep_hard_irq(int irq, void *arg)
spurious = 0;
}
+ if (status_l0 & APPL_INTR_STATUS_L0_INT_INT) {
+ status_l1 = appl_readl(pcie, APPL_INTR_STATUS_L1_8_0);
+ /* Interrupt is handled by dma driver, don't treat it as spurious */
+ if (status_l1 & APPL_INTR_STATUS_L1_8_0_EDMA_INT_MASK)
+ spurious = 0;
+ }
+
if (spurious) {
dev_warn(pcie->dev, "Random interrupt (STATUS = 0x%08X)\n",
status_l0);
@@ -774,6 +782,7 @@ static void tegra_pcie_enable_intx_interrupts(struct dw_pcie_rp *pp)
val |= APPL_INTR_EN_L1_8_INTX_EN;
val |= APPL_INTR_EN_L1_8_AUTO_BW_INT_EN;
val |= APPL_INTR_EN_L1_8_BW_MGT_INT_EN;
+ val |= APPL_INTR_EN_L1_8_EDMA_INT_EN;
if (IS_ENABLED(CONFIG_PCIEAER))
val |= APPL_INTR_EN_L1_8_AER_INT_EN;
appl_writel(pcie, val, APPL_INTR_EN_L1_8_0);
@@ -1839,6 +1848,7 @@ static void pex_ep_event_pex_rst_deassert(struct tegra_pcie_dw *pcie)
val |= APPL_INTR_EN_L0_0_SYS_INTR_EN;
val |= APPL_INTR_EN_L0_0_LINK_STATE_INT_EN;
val |= APPL_INTR_EN_L0_0_PCI_CMD_EN_INT_EN;
+ val |= APPL_INTR_EN_L0_0_INT_INT_EN;
appl_writel(pcie, val, APPL_INTR_EN_L0_0);
val = appl_readl(pcie, APPL_INTR_EN_L1_0_0);
@@ -1846,6 +1856,10 @@ static void pex_ep_event_pex_rst_deassert(struct tegra_pcie_dw *pcie)
val |= APPL_INTR_EN_L1_0_0_RDLH_LINK_UP_INT_EN;
appl_writel(pcie, val, APPL_INTR_EN_L1_0_0);
+ val = appl_readl(pcie, APPL_INTR_EN_L1_8_0);
+ val |= APPL_INTR_EN_L1_8_EDMA_INT_EN;
+ appl_writel(pcie, val, APPL_INTR_EN_L1_8_0);
+
reset_control_deassert(pcie->core_rst);
val = dw_pcie_readl_dbi(pci, PCIE_LINK_WIDTH_SPEED_CONTROL);
--
2.34.1
^ permalink raw reply related [flat|nested] 33+ messages in thread* [PATCH V4 11/22] PCI: tegra194: Enable hardware hot reset mode in Endpoint
2026-01-26 7:44 [PATCH V4 00/22] Enhancements to pcie-tegra194 driver Manikanta Maddireddy
` (9 preceding siblings ...)
2026-01-26 7:45 ` [PATCH V4 10/22] PCI: tegra194: Enable DMA interrupt Manikanta Maddireddy
@ 2026-01-26 7:45 ` Manikanta Maddireddy
2026-01-26 7:45 ` [PATCH V4 12/22] PCI: tegra194: Allow system suspend when the Endpoint link is not up Manikanta Maddireddy
` (12 subsequent siblings)
23 siblings, 0 replies; 33+ messages in thread
From: Manikanta Maddireddy @ 2026-01-26 7:45 UTC (permalink / raw)
To: bhelgaas, lpieralisi, kwilczynski, mani, robh, krzk+dt, conor+dt,
thierry.reding, jonathanh, jingoohan1, vidyas, cassel,
18255117159
Cc: linux-pci, devicetree, linux-tegra, linux-kernel,
Manikanta Maddireddy
From: Vidya Sagar <vidyas@nvidia.com>
When PCIe link goes down, hardware can retrain the link and try to link up.
To enable this feature, program the APPL_CTRL register with hardware hot
reset with immediate LTSSM enable mode.
Signed-off-by: Vidya Sagar <vidyas@nvidia.com>
Signed-off-by: Manikanta Maddireddy <mmaddireddy@nvidia.com>
---
V4:
* None
V3:
* This is a new patch in this series
drivers/pci/controller/dwc/pcie-tegra194.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/pci/controller/dwc/pcie-tegra194.c b/drivers/pci/controller/dwc/pcie-tegra194.c
index e5168754b92d..5fa4d2adf64e 100644
--- a/drivers/pci/controller/dwc/pcie-tegra194.c
+++ b/drivers/pci/controller/dwc/pcie-tegra194.c
@@ -1825,6 +1825,8 @@ static void pex_ep_event_pex_rst_deassert(struct tegra_pcie_dw *pcie)
val = appl_readl(pcie, APPL_CTRL);
val |= APPL_CTRL_SYS_PRE_DET_STATE;
val |= APPL_CTRL_HW_HOT_RST_EN;
+ val &= ~(APPL_CTRL_HW_HOT_RST_MODE_MASK << APPL_CTRL_HW_HOT_RST_MODE_SHIFT);
+ val |= (APPL_CTRL_HW_HOT_RST_MODE_IMDT_RST_LTSSM_EN << APPL_CTRL_HW_HOT_RST_MODE_SHIFT);
appl_writel(pcie, val, APPL_CTRL);
val = appl_readl(pcie, APPL_CFG_MISC);
--
2.34.1
^ permalink raw reply related [flat|nested] 33+ messages in thread* [PATCH V4 12/22] PCI: tegra194: Allow system suspend when the Endpoint link is not up
2026-01-26 7:44 [PATCH V4 00/22] Enhancements to pcie-tegra194 driver Manikanta Maddireddy
` (10 preceding siblings ...)
2026-01-26 7:45 ` [PATCH V4 11/22] PCI: tegra194: Enable hardware hot reset mode in Endpoint Manikanta Maddireddy
@ 2026-01-26 7:45 ` Manikanta Maddireddy
2026-01-26 7:45 ` [PATCH V4 13/22] PCI: tegra194: Disable L1.2 capability of Tegra234 EP Manikanta Maddireddy
` (11 subsequent siblings)
23 siblings, 0 replies; 33+ messages in thread
From: Manikanta Maddireddy @ 2026-01-26 7:45 UTC (permalink / raw)
To: bhelgaas, lpieralisi, kwilczynski, mani, robh, krzk+dt, conor+dt,
thierry.reding, jonathanh, jingoohan1, vidyas, cassel,
18255117159
Cc: linux-pci, devicetree, linux-tegra, linux-kernel,
Manikanta Maddireddy
From: Vidya Sagar <vidyas@nvidia.com>
Only a Root port initiates the L2 sequence. PCIe link is kept in L2 state
during suspend. If Endpoint mode is enabled and the link is up, the
software cannot proceed with suspend. However, when the PCIe Endpoint
driver is probed, but the PCIe link is not up, Tegra can go into suspend
state. So, allow system to suspend in this case.
Signed-off-by: Vidya Sagar <vidyas@nvidia.com>
Signed-off-by: Manikanta Maddireddy <mmaddireddy@nvidia.com>
---
V4:
* None
V3:
* This is a new patch in this series
drivers/pci/controller/dwc/pcie-tegra194.c | 31 +++++++++++++++++-----
1 file changed, 25 insertions(+), 6 deletions(-)
diff --git a/drivers/pci/controller/dwc/pcie-tegra194.c b/drivers/pci/controller/dwc/pcie-tegra194.c
index 5fa4d2adf64e..04e6c34f47f0 100644
--- a/drivers/pci/controller/dwc/pcie-tegra194.c
+++ b/drivers/pci/controller/dwc/pcie-tegra194.c
@@ -2341,16 +2341,28 @@ static void tegra_pcie_dw_remove(struct platform_device *pdev)
gpiod_set_value(pcie->pex_refclk_sel_gpiod, 0);
}
-static int tegra_pcie_dw_suspend_late(struct device *dev)
+static int tegra_pcie_dw_suspend(struct device *dev)
{
struct tegra_pcie_dw *pcie = dev_get_drvdata(dev);
- u32 val;
if (pcie->of_data->mode == DW_PCIE_EP_TYPE) {
- dev_err(dev, "Failed to Suspend as Tegra PCIe is in EP mode\n");
- return -EPERM;
+ if (pcie->ep_state == EP_STATE_ENABLED) {
+ dev_err(dev, "Tegra PCIe is in EP mode, suspend not allowed\n");
+ return -EPERM;
+ }
+
+ disable_irq(pcie->pex_rst_irq);
+ return 0;
}
+ return 0;
+}
+
+static int tegra_pcie_dw_suspend_late(struct device *dev)
+{
+ struct tegra_pcie_dw *pcie = dev_get_drvdata(dev);
+ u32 val;
+
if (!pcie->link_state)
return 0;
@@ -2370,6 +2382,9 @@ static int tegra_pcie_dw_suspend_noirq(struct device *dev)
{
struct tegra_pcie_dw *pcie = dev_get_drvdata(dev);
+ if (pcie->of_data->mode == DW_PCIE_EP_TYPE)
+ return 0;
+
if (!pcie->link_state)
return 0;
@@ -2385,6 +2400,9 @@ static int tegra_pcie_dw_resume_noirq(struct device *dev)
struct tegra_pcie_dw *pcie = dev_get_drvdata(dev);
int ret;
+ if (pcie->of_data->mode == DW_PCIE_EP_TYPE)
+ return 0;
+
if (!pcie->link_state)
return 0;
@@ -2417,8 +2435,8 @@ static int tegra_pcie_dw_resume_early(struct device *dev)
u32 val;
if (pcie->of_data->mode == DW_PCIE_EP_TYPE) {
- dev_err(dev, "Suspend is not supported in EP mode");
- return -ENOTSUPP;
+ enable_irq(pcie->pex_rst_irq);
+ return 0;
}
if (!pcie->link_state)
@@ -2524,6 +2542,7 @@ static const struct of_device_id tegra_pcie_dw_of_match[] = {
};
static const struct dev_pm_ops tegra_pcie_dw_pm_ops = {
+ .suspend = tegra_pcie_dw_suspend,
.suspend_late = tegra_pcie_dw_suspend_late,
.suspend_noirq = tegra_pcie_dw_suspend_noirq,
.resume_noirq = tegra_pcie_dw_resume_noirq,
--
2.34.1
^ permalink raw reply related [flat|nested] 33+ messages in thread* [PATCH V4 13/22] PCI: tegra194: Disable L1.2 capability of Tegra234 EP
2026-01-26 7:44 [PATCH V4 00/22] Enhancements to pcie-tegra194 driver Manikanta Maddireddy
` (11 preceding siblings ...)
2026-01-26 7:45 ` [PATCH V4 12/22] PCI: tegra194: Allow system suspend when the Endpoint link is not up Manikanta Maddireddy
@ 2026-01-26 7:45 ` Manikanta Maddireddy
2026-01-26 7:45 ` [PATCH V4 14/22] PCI: tegra194: Set LTR message request before PCIe link up Manikanta Maddireddy
` (10 subsequent siblings)
23 siblings, 0 replies; 33+ messages in thread
From: Manikanta Maddireddy @ 2026-01-26 7:45 UTC (permalink / raw)
To: bhelgaas, lpieralisi, kwilczynski, mani, robh, krzk+dt, conor+dt,
thierry.reding, jonathanh, jingoohan1, vidyas, cassel,
18255117159
Cc: linux-pci, devicetree, linux-tegra, linux-kernel,
Manikanta Maddireddy
From: Vidya Sagar <vidyas@nvidia.com>
When Tegra234 is operating in the endpoint mode with L1.2 enabled, PCIe
link goes down during L1.2 exit. This is because Tegra234 is powering up
UPHY PLL immediately without making sure that the REFCLK is stable.
This is causing UPHY PLL to not lock to the correct frequency and leading
to link going down. There is no hardware fix for this, hence do not
advertise the L1.2 capability in the endpoint mode.
Signed-off-by: Vidya Sagar <vidyas@nvidia.com>
Signed-off-by: Manikanta Maddireddy <mmaddireddy@nvidia.com>
---
V4:
* Reworked the change to resolve conflicts.
V3:
* This is a new patch in this series
drivers/pci/controller/dwc/pcie-tegra194.c | 18 ++++++++++++++++++
1 file changed, 18 insertions(+)
diff --git a/drivers/pci/controller/dwc/pcie-tegra194.c b/drivers/pci/controller/dwc/pcie-tegra194.c
index 04e6c34f47f0..5a3e85c53dd7 100644
--- a/drivers/pci/controller/dwc/pcie-tegra194.c
+++ b/drivers/pci/controller/dwc/pcie-tegra194.c
@@ -239,6 +239,7 @@ struct tegra_pcie_dw_of_data {
bool has_sbr_reset_fix;
bool has_l1ss_exit_fix;
bool has_ltr_req_fix;
+ bool disable_l1_2;
u32 cdm_chk_int_en_bit;
u32 gen4_preset_vec;
u8 n_fts[2];
@@ -700,6 +701,22 @@ static void init_host_aspm(struct tegra_pcie_dw *pcie)
if (pcie->supports_clkreq)
pci->l1ss_support = true;
+ /*
+ * Disable L1.2 capability advertisement for Tegra234 Endpoint mode.
+ * Tegra234 has a hardware bug where during L1.2 exit, the UPHY PLL is
+ * powered up immediately without waiting for REFCLK to stabilize. This
+ * causes the PLL to fail to lock to the correct frequency, resulting in
+ * PCIe link loss. Since there is no hardware fix available, we prevent
+ * the Endpoint from advertising L1.2 support by clearing the L1.2 bits
+ * in the L1 PM Substates Capabilities register. This ensures the host
+ * will not attempt to enter L1.2 state with this Endpoint.
+ */
+ if (pcie->of_data->disable_l1_2 && (pcie->of_data->mode == DW_PCIE_EP_TYPE)) {
+ val = dw_pcie_readl_dbi(pci, l1ss + PCI_L1SS_CAP);
+ val &= ~(PCI_L1SS_CAP_PCIPM_L1_2 | PCI_L1SS_CAP_ASPM_L1_2);
+ dw_pcie_writel_dbi(pci, l1ss + PCI_L1SS_CAP, val);
+ }
+
/* Program L0s and L1 entrance latencies */
val = dw_pcie_readl_dbi(pci, PCIE_PORT_AFR);
val &= ~PORT_AFR_L0S_ENTRANCE_LAT_MASK;
@@ -2515,6 +2532,7 @@ static const struct tegra_pcie_dw_of_data tegra234_pcie_dw_ep_of_data = {
.mode = DW_PCIE_EP_TYPE,
.has_l1ss_exit_fix = true,
.has_ltr_req_fix = true,
+ .disable_l1_2 = true,
.cdm_chk_int_en_bit = BIT(18),
/* Gen4 - 6, 8 and 9 presets enabled */
.gen4_preset_vec = 0x340,
--
2.34.1
^ permalink raw reply related [flat|nested] 33+ messages in thread* [PATCH V4 14/22] PCI: tegra194: Set LTR message request before PCIe link up
2026-01-26 7:44 [PATCH V4 00/22] Enhancements to pcie-tegra194 driver Manikanta Maddireddy
` (12 preceding siblings ...)
2026-01-26 7:45 ` [PATCH V4 13/22] PCI: tegra194: Disable L1.2 capability of Tegra234 EP Manikanta Maddireddy
@ 2026-01-26 7:45 ` Manikanta Maddireddy
2026-01-26 7:45 ` [PATCH V4 15/22] PCI: tegra194: Don't force the device into the D0 state before L2 Manikanta Maddireddy
` (9 subsequent siblings)
23 siblings, 0 replies; 33+ messages in thread
From: Manikanta Maddireddy @ 2026-01-26 7:45 UTC (permalink / raw)
To: bhelgaas, lpieralisi, kwilczynski, mani, robh, krzk+dt, conor+dt,
thierry.reding, jonathanh, jingoohan1, vidyas, cassel,
18255117159
Cc: linux-pci, devicetree, linux-tegra, linux-kernel,
Manikanta Maddireddy
From: Vidya Sagar <vidyas@nvidia.com>
LTR message should be sent as soon as the root port enables LTR in the
endpoint. Set snoop & no snoop LTR timing and LTR message request before
PCIe links up. This ensures that LTR message is sent upstream as soon as
LTR is enabled.
Signed-off-by: Vidya Sagar <vidyas@nvidia.com>
Signed-off-by: Manikanta Maddireddy <mmaddireddy@nvidia.com>
---
V4:
* None
V3:
* This is a new patch in this series
drivers/pci/controller/dwc/pcie-tegra194.c | 15 ++++++---------
1 file changed, 6 insertions(+), 9 deletions(-)
diff --git a/drivers/pci/controller/dwc/pcie-tegra194.c b/drivers/pci/controller/dwc/pcie-tegra194.c
index 5a3e85c53dd7..6fcfff93d4bc 100644
--- a/drivers/pci/controller/dwc/pcie-tegra194.c
+++ b/drivers/pci/controller/dwc/pcie-tegra194.c
@@ -126,6 +126,7 @@
#define APPL_LTR_MSG_1 0xC4
#define LTR_MSG_REQ BIT(15)
+#define LTR_MST_NO_SNOOP_SHIFT 16
#define LTR_NOSNOOP_MSG_REQ BIT(31)
#define APPL_LTR_MSG_2 0xC8
@@ -491,15 +492,6 @@ static irqreturn_t tegra_pcie_ep_irq_thread(int irq, void *arg)
if (val & PCI_COMMAND_MASTER) {
ktime_t timeout;
- /* 110us for both snoop and no-snoop */
- val = FIELD_PREP(PCI_LTR_VALUE_MASK, 110) |
- FIELD_PREP(PCI_LTR_SCALE_MASK, 2) |
- LTR_MSG_REQ |
- FIELD_PREP(PCI_LTR_NOSNOOP_VALUE, 110) |
- FIELD_PREP(PCI_LTR_NOSNOOP_SCALE, 2) |
- LTR_NOSNOOP_MSG_REQ;
- appl_writel(pcie, val, APPL_LTR_MSG_1);
-
/* Send LTR upstream */
val = appl_readl(pcie, APPL_LTR_MSG_2);
val |= APPL_LTR_MSG_2_LTR_MSG_REQ_STATE;
@@ -1879,6 +1871,11 @@ static void pex_ep_event_pex_rst_deassert(struct tegra_pcie_dw *pcie)
val |= APPL_INTR_EN_L1_8_EDMA_INT_EN;
appl_writel(pcie, val, APPL_INTR_EN_L1_8_0);
+ /* 110us for both snoop and no-snoop */
+ val = 110 | (2 << PCI_LTR_SCALE_SHIFT) | LTR_MSG_REQ;
+ val |= (val << LTR_MST_NO_SNOOP_SHIFT);
+ appl_writel(pcie, val, APPL_LTR_MSG_1);
+
reset_control_deassert(pcie->core_rst);
val = dw_pcie_readl_dbi(pci, PCIE_LINK_WIDTH_SPEED_CONTROL);
--
2.34.1
^ permalink raw reply related [flat|nested] 33+ messages in thread* [PATCH V4 15/22] PCI: tegra194: Don't force the device into the D0 state before L2
2026-01-26 7:44 [PATCH V4 00/22] Enhancements to pcie-tegra194 driver Manikanta Maddireddy
` (13 preceding siblings ...)
2026-01-26 7:45 ` [PATCH V4 14/22] PCI: tegra194: Set LTR message request before PCIe link up Manikanta Maddireddy
@ 2026-01-26 7:45 ` Manikanta Maddireddy
2026-02-02 13:27 ` Jon Hunter
2026-01-26 7:45 ` [PATCH V4 16/22] PCI: tegra194: Free up EP resources during remove() Manikanta Maddireddy
` (8 subsequent siblings)
23 siblings, 1 reply; 33+ messages in thread
From: Manikanta Maddireddy @ 2026-01-26 7:45 UTC (permalink / raw)
To: bhelgaas, lpieralisi, kwilczynski, mani, robh, krzk+dt, conor+dt,
thierry.reding, jonathanh, jingoohan1, vidyas, cassel,
18255117159
Cc: linux-pci, devicetree, linux-tegra, linux-kernel,
Manikanta Maddireddy
From: Vidya Sagar <vidyas@nvidia.com>
As per PCIe CEM spec rev 4.0 ver 1.0 sec 2.3, the PCIe endpoint device
should be in D3 state to assert wake# pin. This takes precedence over PCI
Express Base r4.0 v1.0 September 27-2017, 5.2 Link State Power Management
which states that the device can be put into D0 state before taking the
link to L2 state. So, to enable the wake functionality for endpoints, do
not force the devices to D0 state before taking the link to L2 state.
There is no functional issue with the endpoints where the link doesn't go
into L2 state (the reason why the earlier change was made in the first
place) as the root port proceeds with the usual flow post PME timeout.
Fixes: 56e15a238d92 ("PCI: tegra: Add Tegra194 PCIe support")
Signed-off-by: Vidya Sagar <vidyas@nvidia.com>
Signed-off-by: Manikanta Maddireddy <mmaddireddy@nvidia.com>
---
V4:
* None
V3:
* This is a new patch in this series
drivers/pci/controller/dwc/pcie-tegra194.c | 41 ----------------------
1 file changed, 41 deletions(-)
diff --git a/drivers/pci/controller/dwc/pcie-tegra194.c b/drivers/pci/controller/dwc/pcie-tegra194.c
index 6fcfff93d4bc..1a269397150a 100644
--- a/drivers/pci/controller/dwc/pcie-tegra194.c
+++ b/drivers/pci/controller/dwc/pcie-tegra194.c
@@ -1283,44 +1283,6 @@ static int tegra_pcie_bpmp_set_pll_state(struct tegra_pcie_dw *pcie,
return 0;
}
-static void tegra_pcie_downstream_dev_to_D0(struct tegra_pcie_dw *pcie)
-{
- struct dw_pcie_rp *pp = &pcie->pci.pp;
- struct pci_bus *child, *root_port_bus = NULL;
- struct pci_dev *pdev;
-
- /*
- * link doesn't go into L2 state with some of the endpoints with Tegra
- * if they are not in D0 state. So, need to make sure that immediate
- * downstream devices are in D0 state before sending PME_TurnOff to put
- * link into L2 state.
- * This is as per PCI Express Base r4.0 v1.0 September 27-2017,
- * 5.2 Link State Power Management (Page #428).
- */
-
- list_for_each_entry(child, &pp->bridge->bus->children, node) {
- if (child->parent == pp->bridge->bus) {
- root_port_bus = child;
- break;
- }
- }
-
- if (!root_port_bus) {
- dev_err(pcie->dev, "Failed to find downstream bus of Root Port\n");
- return;
- }
-
- /* Bring downstream devices to D0 if they are not already in */
- list_for_each_entry(pdev, &root_port_bus->devices, bus_list) {
- if (PCI_SLOT(pdev->devfn) == 0) {
- if (pci_set_power_state(pdev, PCI_D0))
- dev_err(pcie->dev,
- "Failed to transition %s to D0 state\n",
- dev_name(&pdev->dev));
- }
- }
-}
-
static int tegra_pcie_get_slot_regulators(struct tegra_pcie_dw *pcie)
{
pcie->slot_ctl_3v3 = devm_regulator_get_optional(pcie->dev, "vpcie3v3");
@@ -1650,7 +1612,6 @@ static void tegra_pcie_dw_pme_turnoff(struct tegra_pcie_dw *pcie)
static void tegra_pcie_deinit_controller(struct tegra_pcie_dw *pcie)
{
- tegra_pcie_downstream_dev_to_D0(pcie);
dw_pcie_host_deinit(&pcie->pci.pp);
tegra_pcie_dw_pme_turnoff(pcie);
tegra_pcie_unconfig_controller(pcie);
@@ -2402,7 +2363,6 @@ static int tegra_pcie_dw_suspend_noirq(struct device *dev)
if (!pcie->link_state)
return 0;
- tegra_pcie_downstream_dev_to_D0(pcie);
tegra_pcie_dw_pme_turnoff(pcie);
tegra_pcie_unconfig_controller(pcie);
@@ -2479,7 +2439,6 @@ static void tegra_pcie_dw_shutdown(struct platform_device *pdev)
return;
debugfs_remove_recursive(pcie->debugfs);
- tegra_pcie_downstream_dev_to_D0(pcie);
disable_irq(pcie->pci.pp.irq);
if (IS_ENABLED(CONFIG_PCI_MSI))
--
2.34.1
^ permalink raw reply related [flat|nested] 33+ messages in thread* Re: [PATCH V4 15/22] PCI: tegra194: Don't force the device into the D0 state before L2
2026-01-26 7:45 ` [PATCH V4 15/22] PCI: tegra194: Don't force the device into the D0 state before L2 Manikanta Maddireddy
@ 2026-02-02 13:27 ` Jon Hunter
0 siblings, 0 replies; 33+ messages in thread
From: Jon Hunter @ 2026-02-02 13:27 UTC (permalink / raw)
To: Manikanta Maddireddy, bhelgaas, lpieralisi, kwilczynski, mani,
robh, krzk+dt, conor+dt, thierry.reding, jingoohan1, vidyas,
cassel, 18255117159
Cc: linux-pci, devicetree, linux-tegra, linux-kernel
On 26/01/2026 07:45, Manikanta Maddireddy wrote:
> From: Vidya Sagar <vidyas@nvidia.com>
>
> As per PCIe CEM spec rev 4.0 ver 1.0 sec 2.3, the PCIe endpoint device
> should be in D3 state to assert wake# pin. This takes precedence over PCI
> Express Base r4.0 v1.0 September 27-2017, 5.2 Link State Power Management
> which states that the device can be put into D0 state before taking the
> link to L2 state. So, to enable the wake functionality for endpoints, do
> not force the devices to D0 state before taking the link to L2 state.
> There is no functional issue with the endpoints where the link doesn't go
> into L2 state (the reason why the earlier change was made in the first
> place) as the root port proceeds with the usual flow post PME timeout.
>
> Fixes: 56e15a238d92 ("PCI: tegra: Add Tegra194 PCIe support")
>
Drop the extra line here between 'Fixes:' and Signed-off-by.
> Signed-off-by: Vidya Sagar <vidyas@nvidia.com>
> Signed-off-by: Manikanta Maddireddy <mmaddireddy@nvidia.com>
> ---
> V4:
> * None
>
> V3:
> * This is a new patch in this series
>
> drivers/pci/controller/dwc/pcie-tegra194.c | 41 ----------------------
> 1 file changed, 41 deletions(-)
>
> diff --git a/drivers/pci/controller/dwc/pcie-tegra194.c b/drivers/pci/controller/dwc/pcie-tegra194.c
> index 6fcfff93d4bc..1a269397150a 100644
> --- a/drivers/pci/controller/dwc/pcie-tegra194.c
> +++ b/drivers/pci/controller/dwc/pcie-tegra194.c
> @@ -1283,44 +1283,6 @@ static int tegra_pcie_bpmp_set_pll_state(struct tegra_pcie_dw *pcie,
> return 0;
> }
>
> -static void tegra_pcie_downstream_dev_to_D0(struct tegra_pcie_dw *pcie)
> -{
> - struct dw_pcie_rp *pp = &pcie->pci.pp;
> - struct pci_bus *child, *root_port_bus = NULL;
> - struct pci_dev *pdev;
> -
> - /*
> - * link doesn't go into L2 state with some of the endpoints with Tegra
> - * if they are not in D0 state. So, need to make sure that immediate
> - * downstream devices are in D0 state before sending PME_TurnOff to put
> - * link into L2 state.
> - * This is as per PCI Express Base r4.0 v1.0 September 27-2017,
> - * 5.2 Link State Power Management (Page #428).
> - */
> -
> - list_for_each_entry(child, &pp->bridge->bus->children, node) {
> - if (child->parent == pp->bridge->bus) {
> - root_port_bus = child;
> - break;
> - }
> - }
> -
> - if (!root_port_bus) {
> - dev_err(pcie->dev, "Failed to find downstream bus of Root Port\n");
> - return;
> - }
> -
> - /* Bring downstream devices to D0 if they are not already in */
> - list_for_each_entry(pdev, &root_port_bus->devices, bus_list) {
> - if (PCI_SLOT(pdev->devfn) == 0) {
> - if (pci_set_power_state(pdev, PCI_D0))
> - dev_err(pcie->dev,
> - "Failed to transition %s to D0 state\n",
> - dev_name(&pdev->dev));
> - }
> - }
> -}
> -
> static int tegra_pcie_get_slot_regulators(struct tegra_pcie_dw *pcie)
> {
> pcie->slot_ctl_3v3 = devm_regulator_get_optional(pcie->dev, "vpcie3v3");
> @@ -1650,7 +1612,6 @@ static void tegra_pcie_dw_pme_turnoff(struct tegra_pcie_dw *pcie)
>
> static void tegra_pcie_deinit_controller(struct tegra_pcie_dw *pcie)
> {
> - tegra_pcie_downstream_dev_to_D0(pcie);
> dw_pcie_host_deinit(&pcie->pci.pp);
> tegra_pcie_dw_pme_turnoff(pcie);
> tegra_pcie_unconfig_controller(pcie);
> @@ -2402,7 +2363,6 @@ static int tegra_pcie_dw_suspend_noirq(struct device *dev)
> if (!pcie->link_state)
> return 0;
>
> - tegra_pcie_downstream_dev_to_D0(pcie);
> tegra_pcie_dw_pme_turnoff(pcie);
> tegra_pcie_unconfig_controller(pcie);
>
> @@ -2479,7 +2439,6 @@ static void tegra_pcie_dw_shutdown(struct platform_device *pdev)
> return;
>
> debugfs_remove_recursive(pcie->debugfs);
> - tegra_pcie_downstream_dev_to_D0(pcie);
>
> disable_irq(pcie->pci.pp.irq);
> if (IS_ENABLED(CONFIG_PCI_MSI))
--
nvpublic
^ permalink raw reply [flat|nested] 33+ messages in thread
* [PATCH V4 16/22] PCI: tegra194: Free up EP resources during remove()
2026-01-26 7:44 [PATCH V4 00/22] Enhancements to pcie-tegra194 driver Manikanta Maddireddy
` (14 preceding siblings ...)
2026-01-26 7:45 ` [PATCH V4 15/22] PCI: tegra194: Don't force the device into the D0 state before L2 Manikanta Maddireddy
@ 2026-01-26 7:45 ` Manikanta Maddireddy
2026-02-02 13:28 ` Jon Hunter
2026-01-26 7:45 ` [PATCH V4 17/22] dt-bindings: PCI: tegra194: Add monitor clock support Manikanta Maddireddy
` (7 subsequent siblings)
23 siblings, 1 reply; 33+ messages in thread
From: Manikanta Maddireddy @ 2026-01-26 7:45 UTC (permalink / raw)
To: bhelgaas, lpieralisi, kwilczynski, mani, robh, krzk+dt, conor+dt,
thierry.reding, jonathanh, jingoohan1, vidyas, cassel,
18255117159
Cc: linux-pci, devicetree, linux-tegra, linux-kernel,
Manikanta Maddireddy
From: Vidya Sagar <vidyas@nvidia.com>
Free up the resources during remove() that were acquired by the DesignWare
driver for the endpoint mode during probe().
Signed-off-by: Vidya Sagar <vidyas@nvidia.com>
Signed-off-by: Manikanta Maddireddy <mmaddireddy@nvidia.com>
---
V4:
* None
V3:
* This is a new patch in this series
drivers/pci/controller/dwc/pcie-tegra194.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/pci/controller/dwc/pcie-tegra194.c b/drivers/pci/controller/dwc/pcie-tegra194.c
index 1a269397150a..d490dcebf960 100644
--- a/drivers/pci/controller/dwc/pcie-tegra194.c
+++ b/drivers/pci/controller/dwc/pcie-tegra194.c
@@ -2297,6 +2297,7 @@ static int tegra_pcie_dw_probe(struct platform_device *pdev)
static void tegra_pcie_dw_remove(struct platform_device *pdev)
{
struct tegra_pcie_dw *pcie = platform_get_drvdata(pdev);
+ struct dw_pcie_ep *ep = &pcie->pci.ep;
if (pcie->of_data->mode == DW_PCIE_RC_TYPE) {
if (!pcie->link_state)
@@ -2308,6 +2309,7 @@ static void tegra_pcie_dw_remove(struct platform_device *pdev)
} else {
disable_irq(pcie->pex_rst_irq);
pex_ep_event_pex_rst_assert(pcie);
+ dw_pcie_ep_deinit(ep);
}
pm_runtime_disable(pcie->dev);
--
2.34.1
^ permalink raw reply related [flat|nested] 33+ messages in thread* Re: [PATCH V4 16/22] PCI: tegra194: Free up EP resources during remove()
2026-01-26 7:45 ` [PATCH V4 16/22] PCI: tegra194: Free up EP resources during remove() Manikanta Maddireddy
@ 2026-02-02 13:28 ` Jon Hunter
0 siblings, 0 replies; 33+ messages in thread
From: Jon Hunter @ 2026-02-02 13:28 UTC (permalink / raw)
To: Manikanta Maddireddy, bhelgaas, lpieralisi, kwilczynski, mani,
robh, krzk+dt, conor+dt, thierry.reding, jingoohan1, vidyas,
cassel, 18255117159
Cc: linux-pci, devicetree, linux-tegra, linux-kernel
On 26/01/2026 07:45, Manikanta Maddireddy wrote:
> From: Vidya Sagar <vidyas@nvidia.com>
>
> Free up the resources during remove() that were acquired by the DesignWare
> driver for the endpoint mode during probe().
>
We are missing a Fixes tag here.
> Signed-off-by: Vidya Sagar <vidyas@nvidia.com>
> Signed-off-by: Manikanta Maddireddy <mmaddireddy@nvidia.com>
> ---
> V4:
> * None
>
> V3:
> * This is a new patch in this series
>
> drivers/pci/controller/dwc/pcie-tegra194.c | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/drivers/pci/controller/dwc/pcie-tegra194.c b/drivers/pci/controller/dwc/pcie-tegra194.c
> index 1a269397150a..d490dcebf960 100644
> --- a/drivers/pci/controller/dwc/pcie-tegra194.c
> +++ b/drivers/pci/controller/dwc/pcie-tegra194.c
> @@ -2297,6 +2297,7 @@ static int tegra_pcie_dw_probe(struct platform_device *pdev)
> static void tegra_pcie_dw_remove(struct platform_device *pdev)
> {
> struct tegra_pcie_dw *pcie = platform_get_drvdata(pdev);
> + struct dw_pcie_ep *ep = &pcie->pci.ep;
>
> if (pcie->of_data->mode == DW_PCIE_RC_TYPE) {
> if (!pcie->link_state)
> @@ -2308,6 +2309,7 @@ static void tegra_pcie_dw_remove(struct platform_device *pdev)
> } else {
> disable_irq(pcie->pex_rst_irq);
> pex_ep_event_pex_rst_assert(pcie);
> + dw_pcie_ep_deinit(ep);
> }
>
> pm_runtime_disable(pcie->dev);
--
nvpublic
^ permalink raw reply [flat|nested] 33+ messages in thread
* [PATCH V4 17/22] dt-bindings: PCI: tegra194: Add monitor clock support
2026-01-26 7:44 [PATCH V4 00/22] Enhancements to pcie-tegra194 driver Manikanta Maddireddy
` (15 preceding siblings ...)
2026-01-26 7:45 ` [PATCH V4 16/22] PCI: tegra194: Free up EP resources during remove() Manikanta Maddireddy
@ 2026-01-26 7:45 ` Manikanta Maddireddy
2026-01-29 16:40 ` Rob Herring
2026-01-26 7:45 ` [PATCH V4 18/22] PCI: tegra194: Add core " Manikanta Maddireddy
` (6 subsequent siblings)
23 siblings, 1 reply; 33+ messages in thread
From: Manikanta Maddireddy @ 2026-01-26 7:45 UTC (permalink / raw)
To: bhelgaas, lpieralisi, kwilczynski, mani, robh, krzk+dt, conor+dt,
thierry.reding, jonathanh, jingoohan1, vidyas, cassel,
18255117159
Cc: linux-pci, devicetree, linux-tegra, linux-kernel,
Manikanta Maddireddy
From: Vidya Sagar <vidyas@nvidia.com>
Tegra supports PCIe core clock monitoring for any rate changes that may be
happening because of the link speed changes. This is useful in tracking
any changes in the core clock that are not initiated by the software.
Signed-off-by: Vidya Sagar <vidyas@nvidia.com>
Signed-off-by: Manikanta Maddireddy <mmaddireddy@nvidia.com>
---
V4:
* None
V3:
* This is a new patch in this series
.../devicetree/bindings/pci/nvidia,tegra194-pcie-ep.yaml | 6 +++++-
.../devicetree/bindings/pci/nvidia,tegra194-pcie.yaml | 6 +++++-
2 files changed, 10 insertions(+), 2 deletions(-)
diff --git a/Documentation/devicetree/bindings/pci/nvidia,tegra194-pcie-ep.yaml b/Documentation/devicetree/bindings/pci/nvidia,tegra194-pcie-ep.yaml
index 6d6052a2748f..ca5da919c347 100644
--- a/Documentation/devicetree/bindings/pci/nvidia,tegra194-pcie-ep.yaml
+++ b/Documentation/devicetree/bindings/pci/nvidia,tegra194-pcie-ep.yaml
@@ -55,12 +55,16 @@ properties:
- const: intr
clocks:
+ minItems: 1
items:
- - description: module clock
+ - description: module's core clock
+ - description: module's monitor clock
clock-names:
+ minItems: 1
items:
- const: core
+ - const: core_m
resets:
items:
diff --git a/Documentation/devicetree/bindings/pci/nvidia,tegra194-pcie.yaml b/Documentation/devicetree/bindings/pci/nvidia,tegra194-pcie.yaml
index fe81d52c7277..d0f5f18f5b9f 100644
--- a/Documentation/devicetree/bindings/pci/nvidia,tegra194-pcie.yaml
+++ b/Documentation/devicetree/bindings/pci/nvidia,tegra194-pcie.yaml
@@ -58,12 +58,16 @@ properties:
- const: msi
clocks:
+ minItems: 1
items:
- - description: module clock
+ - description: module's core clock
+ - description: module's monitor clock
clock-names:
+ minItems: 1
items:
- const: core
+ - const: core_m
resets:
items:
--
2.34.1
^ permalink raw reply related [flat|nested] 33+ messages in thread* Re: [PATCH V4 17/22] dt-bindings: PCI: tegra194: Add monitor clock support
2026-01-26 7:45 ` [PATCH V4 17/22] dt-bindings: PCI: tegra194: Add monitor clock support Manikanta Maddireddy
@ 2026-01-29 16:40 ` Rob Herring
2026-02-02 4:34 ` Manikanta Maddireddy
0 siblings, 1 reply; 33+ messages in thread
From: Rob Herring @ 2026-01-29 16:40 UTC (permalink / raw)
To: Manikanta Maddireddy
Cc: bhelgaas, lpieralisi, kwilczynski, mani, krzk+dt, conor+dt,
thierry.reding, jonathanh, jingoohan1, vidyas, cassel,
18255117159, linux-pci, devicetree, linux-tegra, linux-kernel
On Mon, Jan 26, 2026 at 01:15:14PM +0530, Manikanta Maddireddy wrote:
> From: Vidya Sagar <vidyas@nvidia.com>
>
> Tegra supports PCIe core clock monitoring for any rate changes that may be
> happening because of the link speed changes. This is useful in tracking
> any changes in the core clock that are not initiated by the software.
>
> Signed-off-by: Vidya Sagar <vidyas@nvidia.com>
> Signed-off-by: Manikanta Maddireddy <mmaddireddy@nvidia.com>
> ---
> V4:
> * None
>
> V3:
> * This is a new patch in this series
>
> .../devicetree/bindings/pci/nvidia,tegra194-pcie-ep.yaml | 6 +++++-
> .../devicetree/bindings/pci/nvidia,tegra194-pcie.yaml | 6 +++++-
> 2 files changed, 10 insertions(+), 2 deletions(-)
>
> diff --git a/Documentation/devicetree/bindings/pci/nvidia,tegra194-pcie-ep.yaml b/Documentation/devicetree/bindings/pci/nvidia,tegra194-pcie-ep.yaml
> index 6d6052a2748f..ca5da919c347 100644
> --- a/Documentation/devicetree/bindings/pci/nvidia,tegra194-pcie-ep.yaml
> +++ b/Documentation/devicetree/bindings/pci/nvidia,tegra194-pcie-ep.yaml
> @@ -55,12 +55,16 @@ properties:
> - const: intr
>
> clocks:
> + minItems: 1
> items:
> - - description: module clock
> + - description: module's core clock
> + - description: module's monitor clock
Drop "module's"
>
> clock-names:
> + minItems: 1
> items:
> - const: core
> + - const: core_m
I would use "module" unless this corresponds to h/w documentation.
Otherwise,
Reviewed-by: Rob Herring (Arm) <robh@kernel.org>
^ permalink raw reply [flat|nested] 33+ messages in thread
* Re: [PATCH V4 17/22] dt-bindings: PCI: tegra194: Add monitor clock support
2026-01-29 16:40 ` Rob Herring
@ 2026-02-02 4:34 ` Manikanta Maddireddy
0 siblings, 0 replies; 33+ messages in thread
From: Manikanta Maddireddy @ 2026-02-02 4:34 UTC (permalink / raw)
To: Rob Herring
Cc: bhelgaas@google.com, lpieralisi@kernel.org,
kwilczynski@kernel.org, mani@kernel.org, krzk+dt@kernel.org,
conor+dt@kernel.org, thierry.reding@gmail.com, Jon Hunter,
jingoohan1@gmail.com, Vidya Sagar, cassel@kernel.org,
18255117159@163.com, linux-pci@vger.kernel.org,
devicetree@vger.kernel.org, linux-tegra@vger.kernel.org,
linux-kernel@vger.kernel.org
On 29/01/26 10:10 pm, Rob Herring wrote:
> On Mon, Jan 26, 2026 at 01:15:14PM +0530, Manikanta Maddireddy wrote:
>> From: Vidya Sagar <vidyas@nvidia.com>
>>
>> Tegra supports PCIe core clock monitoring for any rate changes that may be
>> happening because of the link speed changes. This is useful in tracking
>> any changes in the core clock that are not initiated by the software.
>>
>> Signed-off-by: Vidya Sagar <vidyas@nvidia.com>
>> Signed-off-by: Manikanta Maddireddy <mmaddireddy@nvidia.com>
>> ---
>> V4:
>> * None
>>
>> V3:
>> * This is a new patch in this series
>>
>> .../devicetree/bindings/pci/nvidia,tegra194-pcie-ep.yaml | 6 +++++-
>> .../devicetree/bindings/pci/nvidia,tegra194-pcie.yaml | 6 +++++-
>> 2 files changed, 10 insertions(+), 2 deletions(-)
>>
>> diff --git a/Documentation/devicetree/bindings/pci/nvidia,tegra194-pcie-ep.yaml b/Documentation/devicetree/bindings/pci/nvidia,tegra194-pcie-ep.yaml
>> index 6d6052a2748f..ca5da919c347 100644
>> --- a/Documentation/devicetree/bindings/pci/nvidia,tegra194-pcie-ep.yaml
>> +++ b/Documentation/devicetree/bindings/pci/nvidia,tegra194-pcie-ep.yaml
>> @@ -55,12 +55,16 @@ properties:
>> - const: intr
>>
>> clocks:
>> + minItems: 1
>> items:
>> - - description: module clock
>> + - description: module's core clock
>> + - description: module's monitor clock
> Drop "module's"
I will fix it in next version.
>
>>
>> clock-names:
>> + minItems: 1
>> items:
>> - const: core
>> + - const: core_m
> I would use "module" unless this corresponds to h/w documentation.
>
> Otherwise,
>
> Reviewed-by: Rob Herring (Arm) <robh@kernel.org>
Thank you for quick review.
HW register to enable the clock is core_m, so I am using same name.
^ permalink raw reply [flat|nested] 33+ messages in thread
* [PATCH V4 18/22] PCI: tegra194: Add core monitor clock support
2026-01-26 7:44 [PATCH V4 00/22] Enhancements to pcie-tegra194 driver Manikanta Maddireddy
` (16 preceding siblings ...)
2026-01-26 7:45 ` [PATCH V4 17/22] dt-bindings: PCI: tegra194: Add monitor clock support Manikanta Maddireddy
@ 2026-01-26 7:45 ` Manikanta Maddireddy
2026-01-26 7:45 ` [PATCH V4 19/22] PCI: tegra194: Add ASPM L1 entrance latency config Manikanta Maddireddy
` (5 subsequent siblings)
23 siblings, 0 replies; 33+ messages in thread
From: Manikanta Maddireddy @ 2026-01-26 7:45 UTC (permalink / raw)
To: bhelgaas, lpieralisi, kwilczynski, mani, robh, krzk+dt, conor+dt,
thierry.reding, jonathanh, jingoohan1, vidyas, cassel,
18255117159
Cc: linux-pci, devicetree, linux-tegra, linux-kernel,
Manikanta Maddireddy
From: Vidya Sagar <vidyas@nvidia.com>
Tegra supports PCIe core clock monitoring for any rate changes that may be
happening because of the link speed changes. This is useful in tracking
any changes in the core clock that are not initiated by the software. This
patch adds support to parse the monitor clock info from device-tree and
enable it if present.
Signed-off-by: Vidya Sagar <vidyas@nvidia.com>
Signed-off-by: Manikanta Maddireddy <mmaddireddy@nvidia.com>
---
V4:
* None
V3:
* This is a new patch in this series
drivers/pci/controller/dwc/pcie-tegra194.c | 18 ++++++++++++++++++
1 file changed, 18 insertions(+)
diff --git a/drivers/pci/controller/dwc/pcie-tegra194.c b/drivers/pci/controller/dwc/pcie-tegra194.c
index d490dcebf960..b5604b879a58 100644
--- a/drivers/pci/controller/dwc/pcie-tegra194.c
+++ b/drivers/pci/controller/dwc/pcie-tegra194.c
@@ -253,6 +253,7 @@ struct tegra_pcie_dw {
struct resource *atu_dma_res;
void __iomem *appl_base;
struct clk *core_clk;
+ struct clk *core_clk_m;
struct reset_control *core_apb_rst;
struct reset_control *core_rst;
struct dw_pcie pci;
@@ -949,6 +950,8 @@ static int tegra_pcie_dw_host_init(struct dw_pcie_rp *pp)
}
clk_set_rate(pcie->core_clk, GEN4_CORE_CLK_FREQ);
+ if (clk_prepare_enable(pcie->core_clk_m))
+ dev_err(pci->dev, "Failed to enable core monitor clock\n");
return 0;
}
@@ -1021,6 +1024,12 @@ static int tegra_pcie_dw_start_link(struct dw_pcie *pci)
val &= ~PCI_DLF_EXCHANGE_ENABLE;
dw_pcie_writel_dbi(pci, offset + PCI_DLF_CAP, val);
+ /*
+ * core_clk_m is enabled as part of host_init callback in
+ * dw_pcie_host_init(). Disable the clock since below
+ * tegra_pcie_dw_host_init() will enable it again.
+ */
+ clk_disable_unprepare(pcie->core_clk_m);
tegra_pcie_dw_host_init(pp);
dw_pcie_setup_rc(pp);
@@ -1612,6 +1621,7 @@ static void tegra_pcie_dw_pme_turnoff(struct tegra_pcie_dw *pcie)
static void tegra_pcie_deinit_controller(struct tegra_pcie_dw *pcie)
{
+ clk_disable_unprepare(pcie->core_clk_m);
dw_pcie_host_deinit(&pcie->pci.pp);
tegra_pcie_dw_pme_turnoff(pcie);
tegra_pcie_unconfig_controller(pcie);
@@ -2169,6 +2179,13 @@ static int tegra_pcie_dw_probe(struct platform_device *pdev)
return PTR_ERR(pcie->core_clk);
}
+ pcie->core_clk_m = devm_clk_get_optional(dev, "core_m");
+ if (IS_ERR(pcie->core_clk_m)) {
+ dev_err(dev, "Failed to get monitor clock: %ld\n",
+ PTR_ERR(pcie->core_clk_m));
+ return PTR_ERR(pcie->core_clk_m);
+ }
+
pcie->appl_res = platform_get_resource_byname(pdev, IORESOURCE_MEM,
"appl");
if (!pcie->appl_res) {
@@ -2365,6 +2382,7 @@ static int tegra_pcie_dw_suspend_noirq(struct device *dev)
if (!pcie->link_state)
return 0;
+ clk_disable_unprepare(pcie->core_clk_m);
tegra_pcie_dw_pme_turnoff(pcie);
tegra_pcie_unconfig_controller(pcie);
--
2.34.1
^ permalink raw reply related [flat|nested] 33+ messages in thread* [PATCH V4 19/22] PCI: tegra194: Add ASPM L1 entrance latency config
2026-01-26 7:44 [PATCH V4 00/22] Enhancements to pcie-tegra194 driver Manikanta Maddireddy
` (17 preceding siblings ...)
2026-01-26 7:45 ` [PATCH V4 18/22] PCI: tegra194: Add core " Manikanta Maddireddy
@ 2026-01-26 7:45 ` Manikanta Maddireddy
2026-02-02 13:28 ` Jon Hunter
2026-01-26 7:45 ` [PATCH V4 20/22] PCI: tegra194: Use HW version number Manikanta Maddireddy
` (4 subsequent siblings)
23 siblings, 1 reply; 33+ messages in thread
From: Manikanta Maddireddy @ 2026-01-26 7:45 UTC (permalink / raw)
To: bhelgaas, lpieralisi, kwilczynski, mani, robh, krzk+dt, conor+dt,
thierry.reding, jonathanh, jingoohan1, vidyas, cassel,
18255117159
Cc: linux-pci, devicetree, linux-tegra, linux-kernel,
Manikanta Maddireddy
For Tegra234, the HW PHY team conducted experiments and determined the
optimal ASPM L1 entrance latency values: 8 us for Root Port mode and
16 us for Endpoint mode. Update the default ASPM L1 entrance latency
configuration accordingly.
Signed-off-by: Manikanta Maddireddy <mmaddireddy@nvidia.com>
---
V4:
* This is a new patch in this series
drivers/pci/controller/dwc/pcie-tegra194.c | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/drivers/pci/controller/dwc/pcie-tegra194.c b/drivers/pci/controller/dwc/pcie-tegra194.c
index b5604b879a58..6543c6d49fc8 100644
--- a/drivers/pci/controller/dwc/pcie-tegra194.c
+++ b/drivers/pci/controller/dwc/pcie-tegra194.c
@@ -244,6 +244,8 @@ struct tegra_pcie_dw_of_data {
u32 cdm_chk_int_en_bit;
u32 gen4_preset_vec;
u8 n_fts[2];
+ /* L1 Latency entrance values(Rest/Prod) */
+ u32 aspm_l1_enter_lat;
};
struct tegra_pcie_dw {
@@ -714,6 +716,8 @@ static void init_host_aspm(struct tegra_pcie_dw *pcie)
val = dw_pcie_readl_dbi(pci, PCIE_PORT_AFR);
val &= ~PORT_AFR_L0S_ENTRANCE_LAT_MASK;
val |= (pcie->aspm_l0s_enter_lat << PORT_AFR_L0S_ENTRANCE_LAT_SHIFT);
+ val &= ~PORT_AFR_L1_ENTRANCE_LAT_MASK;
+ val |= (pcie->of_data->aspm_l1_enter_lat << PORT_AFR_L1_ENTRANCE_LAT_SHIFT);
val |= PORT_AFR_ENTER_ASPM;
dw_pcie_writel_dbi(pci, PCIE_PORT_AFR, val);
}
@@ -2480,6 +2484,7 @@ static const struct tegra_pcie_dw_of_data tegra194_pcie_dw_rc_of_data = {
/* Gen4 - 5, 6, 8 and 9 presets enabled */
.gen4_preset_vec = 0x360,
.n_fts = { 52, 52 },
+ .aspm_l1_enter_lat = 3,
};
static const struct tegra_pcie_dw_of_data tegra194_pcie_dw_ep_of_data = {
@@ -2489,6 +2494,7 @@ static const struct tegra_pcie_dw_of_data tegra194_pcie_dw_ep_of_data = {
/* Gen4 - 5, 6, 8 and 9 presets enabled */
.gen4_preset_vec = 0x360,
.n_fts = { 52, 52 },
+ .aspm_l1_enter_lat = 3,
};
static const struct tegra_pcie_dw_of_data tegra234_pcie_dw_rc_of_data = {
@@ -2501,6 +2507,7 @@ static const struct tegra_pcie_dw_of_data tegra234_pcie_dw_rc_of_data = {
/* Gen4 - 6, 8 and 9 presets enabled */
.gen4_preset_vec = 0x340,
.n_fts = { 52, 80 },
+ .aspm_l1_enter_lat = 4,
};
static const struct tegra_pcie_dw_of_data tegra234_pcie_dw_ep_of_data = {
@@ -2513,6 +2520,7 @@ static const struct tegra_pcie_dw_of_data tegra234_pcie_dw_ep_of_data = {
/* Gen4 - 6, 8 and 9 presets enabled */
.gen4_preset_vec = 0x340,
.n_fts = { 52, 80 },
+ .aspm_l1_enter_lat = 5,
};
static const struct of_device_id tegra_pcie_dw_of_match[] = {
--
2.34.1
^ permalink raw reply related [flat|nested] 33+ messages in thread* Re: [PATCH V4 19/22] PCI: tegra194: Add ASPM L1 entrance latency config
2026-01-26 7:45 ` [PATCH V4 19/22] PCI: tegra194: Add ASPM L1 entrance latency config Manikanta Maddireddy
@ 2026-02-02 13:28 ` Jon Hunter
0 siblings, 0 replies; 33+ messages in thread
From: Jon Hunter @ 2026-02-02 13:28 UTC (permalink / raw)
To: Manikanta Maddireddy, bhelgaas, lpieralisi, kwilczynski, mani,
robh, krzk+dt, conor+dt, thierry.reding, jingoohan1, vidyas,
cassel, 18255117159
Cc: linux-pci, devicetree, linux-tegra, linux-kernel
On 26/01/2026 07:45, Manikanta Maddireddy wrote:
> For Tegra234, the HW PHY team conducted experiments and determined the
> optimal ASPM L1 entrance latency values: 8 us for Root Port mode and
> 16 us for Endpoint mode. Update the default ASPM L1 entrance latency
> configuration accordingly.
>
Fixes tag?
> Signed-off-by: Manikanta Maddireddy <mmaddireddy@nvidia.com>
> ---
> V4:
> * This is a new patch in this series
>
> drivers/pci/controller/dwc/pcie-tegra194.c | 8 ++++++++
> 1 file changed, 8 insertions(+)
>
> diff --git a/drivers/pci/controller/dwc/pcie-tegra194.c b/drivers/pci/controller/dwc/pcie-tegra194.c
> index b5604b879a58..6543c6d49fc8 100644
> --- a/drivers/pci/controller/dwc/pcie-tegra194.c
> +++ b/drivers/pci/controller/dwc/pcie-tegra194.c
> @@ -244,6 +244,8 @@ struct tegra_pcie_dw_of_data {
> u32 cdm_chk_int_en_bit;
> u32 gen4_preset_vec;
> u8 n_fts[2];
> + /* L1 Latency entrance values(Rest/Prod) */
> + u32 aspm_l1_enter_lat;
> };
>
> struct tegra_pcie_dw {
> @@ -714,6 +716,8 @@ static void init_host_aspm(struct tegra_pcie_dw *pcie)
> val = dw_pcie_readl_dbi(pci, PCIE_PORT_AFR);
> val &= ~PORT_AFR_L0S_ENTRANCE_LAT_MASK;
> val |= (pcie->aspm_l0s_enter_lat << PORT_AFR_L0S_ENTRANCE_LAT_SHIFT);
> + val &= ~PORT_AFR_L1_ENTRANCE_LAT_MASK;
> + val |= (pcie->of_data->aspm_l1_enter_lat << PORT_AFR_L1_ENTRANCE_LAT_SHIFT);
> val |= PORT_AFR_ENTER_ASPM;
> dw_pcie_writel_dbi(pci, PCIE_PORT_AFR, val);
> }
> @@ -2480,6 +2484,7 @@ static const struct tegra_pcie_dw_of_data tegra194_pcie_dw_rc_of_data = {
> /* Gen4 - 5, 6, 8 and 9 presets enabled */
> .gen4_preset_vec = 0x360,
> .n_fts = { 52, 52 },
> + .aspm_l1_enter_lat = 3,
> };
>
> static const struct tegra_pcie_dw_of_data tegra194_pcie_dw_ep_of_data = {
> @@ -2489,6 +2494,7 @@ static const struct tegra_pcie_dw_of_data tegra194_pcie_dw_ep_of_data = {
> /* Gen4 - 5, 6, 8 and 9 presets enabled */
> .gen4_preset_vec = 0x360,
> .n_fts = { 52, 52 },
> + .aspm_l1_enter_lat = 3,
> };
>
> static const struct tegra_pcie_dw_of_data tegra234_pcie_dw_rc_of_data = {
> @@ -2501,6 +2507,7 @@ static const struct tegra_pcie_dw_of_data tegra234_pcie_dw_rc_of_data = {
> /* Gen4 - 6, 8 and 9 presets enabled */
> .gen4_preset_vec = 0x340,
> .n_fts = { 52, 80 },
> + .aspm_l1_enter_lat = 4,
> };
>
> static const struct tegra_pcie_dw_of_data tegra234_pcie_dw_ep_of_data = {
> @@ -2513,6 +2520,7 @@ static const struct tegra_pcie_dw_of_data tegra234_pcie_dw_ep_of_data = {
> /* Gen4 - 6, 8 and 9 presets enabled */
> .gen4_preset_vec = 0x340,
> .n_fts = { 52, 80 },
> + .aspm_l1_enter_lat = 5,
> };
>
> static const struct of_device_id tegra_pcie_dw_of_match[] = {
--
nvpublic
^ permalink raw reply [flat|nested] 33+ messages in thread
* [PATCH V4 20/22] PCI: tegra194: Use HW version number
2026-01-26 7:44 [PATCH V4 00/22] Enhancements to pcie-tegra194 driver Manikanta Maddireddy
` (18 preceding siblings ...)
2026-01-26 7:45 ` [PATCH V4 19/22] PCI: tegra194: Add ASPM L1 entrance latency config Manikanta Maddireddy
@ 2026-01-26 7:45 ` Manikanta Maddireddy
2026-02-02 13:30 ` Jon Hunter
2026-01-26 7:45 ` [PATCH V4 21/22] PCI: tegra194: Fix CBB timeout caused by DBI access before core power-on Manikanta Maddireddy
` (3 subsequent siblings)
23 siblings, 1 reply; 33+ messages in thread
From: Manikanta Maddireddy @ 2026-01-26 7:45 UTC (permalink / raw)
To: bhelgaas, lpieralisi, kwilczynski, mani, robh, krzk+dt, conor+dt,
thierry.reding, jonathanh, jingoohan1, vidyas, cassel,
18255117159
Cc: linux-pci, devicetree, linux-tegra, linux-kernel,
Manikanta Maddireddy
Tegra194 PCIe driver uses custom version number to detect Tegra194 and
Tegra234 IPs. With version detect logic added, version check results
in mismatch warnings.
Use HW version numbers in Tegra194 driver to avoid this kernel warnings.
Fixed version check to enable ecrc for Tegra194.
Existing 490A check is left intact in case any HW relying on existing check.
Signed-off-by: Manikanta Maddireddy <mmaddireddy@nvidia.com>
---
V4:
* This is a new patch in this series
drivers/pci/controller/dwc/pcie-designware.c | 2 +-
drivers/pci/controller/dwc/pcie-designware.h | 2 ++
drivers/pci/controller/dwc/pcie-tegra194.c | 4 ++--
3 files changed, 5 insertions(+), 3 deletions(-)
diff --git a/drivers/pci/controller/dwc/pcie-designware.c b/drivers/pci/controller/dwc/pcie-designware.c
index 345365ea97c7..0dac5d2f5a83 100644
--- a/drivers/pci/controller/dwc/pcie-designware.c
+++ b/drivers/pci/controller/dwc/pcie-designware.c
@@ -559,7 +559,7 @@ int dw_pcie_prog_outbound_atu(struct dw_pcie *pci,
if (upper_32_bits(limit_addr) > upper_32_bits(parent_bus_addr) &&
dw_pcie_ver_is_ge(pci, 460A))
val |= PCIE_ATU_INCREASE_REGION_SIZE;
- if (dw_pcie_ver_is(pci, 490A))
+ if (dw_pcie_ver_is(pci, 490A) || dw_pcie_ver_is(pci, 500A))
val = dw_pcie_enable_ecrc(val);
dw_pcie_writel_atu_ob(pci, atu->index, PCIE_ATU_REGION_CTRL1, val);
diff --git a/drivers/pci/controller/dwc/pcie-designware.h b/drivers/pci/controller/dwc/pcie-designware.h
index f4cf1602cc99..5bceadbd2c9f 100644
--- a/drivers/pci/controller/dwc/pcie-designware.h
+++ b/drivers/pci/controller/dwc/pcie-designware.h
@@ -34,8 +34,10 @@
#define DW_PCIE_VER_470A 0x3437302a
#define DW_PCIE_VER_480A 0x3438302a
#define DW_PCIE_VER_490A 0x3439302a
+#define DW_PCIE_VER_500A 0x3530302a
#define DW_PCIE_VER_520A 0x3532302a
#define DW_PCIE_VER_540A 0x3534302a
+#define DW_PCIE_VER_562A 0x3536322a
#define __dw_pcie_ver_cmp(_pci, _ver, _op) \
((_pci)->version _op DW_PCIE_VER_ ## _ver)
diff --git a/drivers/pci/controller/dwc/pcie-tegra194.c b/drivers/pci/controller/dwc/pcie-tegra194.c
index 6543c6d49fc8..156918ba5ab4 100644
--- a/drivers/pci/controller/dwc/pcie-tegra194.c
+++ b/drivers/pci/controller/dwc/pcie-tegra194.c
@@ -35,8 +35,8 @@
#include <soc/tegra/bpmp-abi.h>
#include "../../pci.h"
-#define TEGRA194_DWC_IP_VER 0x490A
-#define TEGRA234_DWC_IP_VER 0x562A
+#define TEGRA194_DWC_IP_VER DW_PCIE_VER_500A
+#define TEGRA234_DWC_IP_VER DW_PCIE_VER_562A
#define APPL_PINMUX 0x0
#define APPL_PINMUX_PEX_RST BIT(0)
--
2.34.1
^ permalink raw reply related [flat|nested] 33+ messages in thread* Re: [PATCH V4 20/22] PCI: tegra194: Use HW version number
2026-01-26 7:45 ` [PATCH V4 20/22] PCI: tegra194: Use HW version number Manikanta Maddireddy
@ 2026-02-02 13:30 ` Jon Hunter
0 siblings, 0 replies; 33+ messages in thread
From: Jon Hunter @ 2026-02-02 13:30 UTC (permalink / raw)
To: Manikanta Maddireddy, bhelgaas, lpieralisi, kwilczynski, mani,
robh, krzk+dt, conor+dt, thierry.reding, jingoohan1, vidyas,
cassel, 18255117159
Cc: linux-pci, devicetree, linux-tegra, linux-kernel
On 26/01/2026 07:45, Manikanta Maddireddy wrote:
> Tegra194 PCIe driver uses custom version number to detect Tegra194 and
> Tegra234 IPs. With version detect logic added, version check results
> in mismatch warnings.
>
> Use HW version numbers in Tegra194 driver to avoid this kernel warnings.
>
> Fixed version check to enable ecrc for Tegra194.
> Existing 490A check is left intact in case any HW relying on existing check.
>
Fixes tag?
> Signed-off-by: Manikanta Maddireddy <mmaddireddy@nvidia.com>
> ---
> V4:
> * This is a new patch in this series
>
> drivers/pci/controller/dwc/pcie-designware.c | 2 +-
> drivers/pci/controller/dwc/pcie-designware.h | 2 ++
> drivers/pci/controller/dwc/pcie-tegra194.c | 4 ++--
> 3 files changed, 5 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/pci/controller/dwc/pcie-designware.c b/drivers/pci/controller/dwc/pcie-designware.c
> index 345365ea97c7..0dac5d2f5a83 100644
> --- a/drivers/pci/controller/dwc/pcie-designware.c
> +++ b/drivers/pci/controller/dwc/pcie-designware.c
> @@ -559,7 +559,7 @@ int dw_pcie_prog_outbound_atu(struct dw_pcie *pci,
> if (upper_32_bits(limit_addr) > upper_32_bits(parent_bus_addr) &&
> dw_pcie_ver_is_ge(pci, 460A))
> val |= PCIE_ATU_INCREASE_REGION_SIZE;
> - if (dw_pcie_ver_is(pci, 490A))
> + if (dw_pcie_ver_is(pci, 490A) || dw_pcie_ver_is(pci, 500A))
> val = dw_pcie_enable_ecrc(val);
> dw_pcie_writel_atu_ob(pci, atu->index, PCIE_ATU_REGION_CTRL1, val);
>
> diff --git a/drivers/pci/controller/dwc/pcie-designware.h b/drivers/pci/controller/dwc/pcie-designware.h
> index f4cf1602cc99..5bceadbd2c9f 100644
> --- a/drivers/pci/controller/dwc/pcie-designware.h
> +++ b/drivers/pci/controller/dwc/pcie-designware.h
> @@ -34,8 +34,10 @@
> #define DW_PCIE_VER_470A 0x3437302a
> #define DW_PCIE_VER_480A 0x3438302a
> #define DW_PCIE_VER_490A 0x3439302a
> +#define DW_PCIE_VER_500A 0x3530302a
> #define DW_PCIE_VER_520A 0x3532302a
> #define DW_PCIE_VER_540A 0x3534302a
> +#define DW_PCIE_VER_562A 0x3536322a
>
> #define __dw_pcie_ver_cmp(_pci, _ver, _op) \
> ((_pci)->version _op DW_PCIE_VER_ ## _ver)
> diff --git a/drivers/pci/controller/dwc/pcie-tegra194.c b/drivers/pci/controller/dwc/pcie-tegra194.c
> index 6543c6d49fc8..156918ba5ab4 100644
> --- a/drivers/pci/controller/dwc/pcie-tegra194.c
> +++ b/drivers/pci/controller/dwc/pcie-tegra194.c
> @@ -35,8 +35,8 @@
> #include <soc/tegra/bpmp-abi.h>
> #include "../../pci.h"
>
> -#define TEGRA194_DWC_IP_VER 0x490A
> -#define TEGRA234_DWC_IP_VER 0x562A
> +#define TEGRA194_DWC_IP_VER DW_PCIE_VER_500A
> +#define TEGRA234_DWC_IP_VER DW_PCIE_VER_562A
>
> #define APPL_PINMUX 0x0
> #define APPL_PINMUX_PEX_RST BIT(0)
--
nvpublic
^ permalink raw reply [flat|nested] 33+ messages in thread
* [PATCH V4 21/22] PCI: tegra194: Fix CBB timeout caused by DBI access before core power-on
2026-01-26 7:44 [PATCH V4 00/22] Enhancements to pcie-tegra194 driver Manikanta Maddireddy
` (19 preceding siblings ...)
2026-01-26 7:45 ` [PATCH V4 20/22] PCI: tegra194: Use HW version number Manikanta Maddireddy
@ 2026-01-26 7:45 ` Manikanta Maddireddy
2026-01-26 7:45 ` [PATCH V4 22/22] PCI: tegra194: Disable PERST IRQ only in Endpoint mode Manikanta Maddireddy
` (2 subsequent siblings)
23 siblings, 0 replies; 33+ messages in thread
From: Manikanta Maddireddy @ 2026-01-26 7:45 UTC (permalink / raw)
To: bhelgaas, lpieralisi, kwilczynski, mani, robh, krzk+dt, conor+dt,
thierry.reding, jonathanh, jingoohan1, vidyas, cassel,
18255117159
Cc: linux-pci, devicetree, linux-tegra, linux-kernel,
Manikanta Maddireddy
When PERST# is deasserted twice (assert -> deassert -> assert -> deassert),
a CBB (Control Backbone) timeout occurs at DBI register offset 0x8bc
(PCIE_MISC_CONTROL_1_OFF). This happens because pci_epc_deinit_notify()
and dw_pcie_ep_cleanup() are called before reset_control_deassert() powers
on the controller core.
The call chain that causes the timeout:
pex_ep_event_pex_rst_deassert()
pci_epc_deinit_notify()
pci_epf_test_epc_deinit()
pci_epf_test_clear_bar()
pci_epc_clear_bar()
dw_pcie_ep_clear_bar()
__dw_pcie_ep_reset_bar()
dw_pcie_dbi_ro_wr_en() <- Accesses 0x8bc DBI register
reset_control_deassert(pcie->core_rst) <- Core powered on HERE
The DBI registers, including PCIE_MISC_CONTROL_1_OFF (0x8bc), are only
accessible after the controller core is powered on via
reset_control_deassert(pcie->core_rst). Accessing them before this point
results in a CBB timeout because the hardware is not yet operational.
Fix this by moving pci_epc_deinit_notify() and dw_pcie_ep_cleanup() to
after reset_control_deassert(pcie->core_rst), ensuring the controller is
fully powered on before any DBI register accesses occur.
Fixes: 40e2125381dc ("PCI: tegra194: Move controller cleanups to pex_ep_event_pex_rst_deassert()")
Signed-off-by: Manikanta Maddireddy <mmaddireddy@nvidia.com>
---
V4:
* This is a new patch in this series
drivers/pci/controller/dwc/pcie-tegra194.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/pci/controller/dwc/pcie-tegra194.c b/drivers/pci/controller/dwc/pcie-tegra194.c
index 156918ba5ab4..b0964f57e8f2 100644
--- a/drivers/pci/controller/dwc/pcie-tegra194.c
+++ b/drivers/pci/controller/dwc/pcie-tegra194.c
@@ -1777,10 +1777,6 @@ static void pex_ep_event_pex_rst_deassert(struct tegra_pcie_dw *pcie)
goto fail_phy;
}
- /* Perform cleanup that requires refclk */
- pci_epc_deinit_notify(pcie->pci.ep.epc);
- dw_pcie_ep_cleanup(&pcie->pci.ep);
-
/* Clear any stale interrupt statuses */
appl_writel(pcie, 0xFFFFFFFF, APPL_INTR_STATUS_L0);
appl_writel(pcie, 0xFFFFFFFF, APPL_INTR_STATUS_L1_0_0);
@@ -1853,6 +1849,10 @@ static void pex_ep_event_pex_rst_deassert(struct tegra_pcie_dw *pcie)
reset_control_deassert(pcie->core_rst);
+ /* Perform cleanup that requires refclk and core reset deasserted */
+ pci_epc_deinit_notify(pcie->pci.ep.epc);
+ dw_pcie_ep_cleanup(&pcie->pci.ep);
+
val = dw_pcie_readl_dbi(pci, PCIE_LINK_WIDTH_SPEED_CONTROL);
val &= ~PORT_LOGIC_SPEED_CHANGE;
dw_pcie_writel_dbi(pci, PCIE_LINK_WIDTH_SPEED_CONTROL, val);
--
2.34.1
^ permalink raw reply related [flat|nested] 33+ messages in thread* [PATCH V4 22/22] PCI: tegra194: Disable PERST IRQ only in Endpoint mode
2026-01-26 7:44 [PATCH V4 00/22] Enhancements to pcie-tegra194 driver Manikanta Maddireddy
` (20 preceding siblings ...)
2026-01-26 7:45 ` [PATCH V4 21/22] PCI: tegra194: Fix CBB timeout caused by DBI access before core power-on Manikanta Maddireddy
@ 2026-01-26 7:45 ` Manikanta Maddireddy
2026-02-02 13:35 ` [PATCH V4 00/22] Enhancements to pcie-tegra194 driver Jon Hunter
2026-02-05 7:55 ` Manivannan Sadhasivam
23 siblings, 0 replies; 33+ messages in thread
From: Manikanta Maddireddy @ 2026-01-26 7:45 UTC (permalink / raw)
To: bhelgaas, lpieralisi, kwilczynski, mani, robh, krzk+dt, conor+dt,
thierry.reding, jonathanh, jingoohan1, vidyas, cassel,
18255117159
Cc: linux-pci, devicetree, linux-tegra, linux-kernel,
Manikanta Maddireddy
The PERST (PERST#) GPIO interrupt is only registered when the controller
is operating in Endpoint mode. In Root Port mode, the PERST GPIO is
configured as an output to control downstream devices, and no interrupt
is registered for it.
Currently, tegra_pcie_dw_stop_link() unconditionally calls disable_irq()
on pex_rst_irq, which causes issues in Root Port mode where this IRQ is
not registered.
Fix this by only disabling the PERST IRQ when operating in Endpoint mode,
where the interrupt is actually registered and used to detect PERST
assertion/deassertion from the host.
Fixes: c57247f940e8 ("PCI: tegra: Add support for PCIe endpoint mode in Tegra194")
Signed-off-by: Manikanta Maddireddy <mmaddireddy@nvidia.com>
---
V4:
* This is a new patch in this series
drivers/pci/controller/dwc/pcie-tegra194.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/pci/controller/dwc/pcie-tegra194.c b/drivers/pci/controller/dwc/pcie-tegra194.c
index b0964f57e8f2..553028a161aa 100644
--- a/drivers/pci/controller/dwc/pcie-tegra194.c
+++ b/drivers/pci/controller/dwc/pcie-tegra194.c
@@ -1060,7 +1060,8 @@ static void tegra_pcie_dw_stop_link(struct dw_pcie *pci)
{
struct tegra_pcie_dw *pcie = to_tegra_pcie(pci);
- disable_irq(pcie->pex_rst_irq);
+ if (pcie->of_data->mode == DW_PCIE_EP_TYPE)
+ disable_irq(pcie->pex_rst_irq);
}
static const struct dw_pcie_ops tegra_dw_pcie_ops = {
--
2.34.1
^ permalink raw reply related [flat|nested] 33+ messages in thread* Re: [PATCH V4 00/22] Enhancements to pcie-tegra194 driver
2026-01-26 7:44 [PATCH V4 00/22] Enhancements to pcie-tegra194 driver Manikanta Maddireddy
` (21 preceding siblings ...)
2026-01-26 7:45 ` [PATCH V4 22/22] PCI: tegra194: Disable PERST IRQ only in Endpoint mode Manikanta Maddireddy
@ 2026-02-02 13:35 ` Jon Hunter
2026-02-05 7:55 ` Manivannan Sadhasivam
23 siblings, 0 replies; 33+ messages in thread
From: Jon Hunter @ 2026-02-02 13:35 UTC (permalink / raw)
To: Manikanta Maddireddy, bhelgaas, lpieralisi, kwilczynski, mani,
robh, krzk+dt, conor+dt, thierry.reding, jingoohan1, vidyas,
cassel, 18255117159
Cc: linux-pci, devicetree, linux-tegra, linux-kernel
On 26/01/2026 07:44, Manikanta Maddireddy wrote:
> This series[1] was originally posted by Vidya Sagar, and I have rebased
> it onto 6.19.0-rc6-next. I addressed review comments, reworked a patch
> and included four new patches. I verified these patches on Jetson AGX
> Orin(Tegra234 SoC).
>
> Disabling L1SS capability based on support-clkreq device tree property
> is moved to common DWC driver, so I reworked below patch to disable
> just L1.2 capability on Tegra234 SoC.
> - PCI: tegra194: Disable L1.2 capability of Tegra234 EP
>
> I added below four new patches to fix bugs, commit message of each
> patch has the details on the bug and fix.
> - PCI: tegra194: Add ASPM L1 entrance latency config
> - PCI: tegra194: Use HW version number
> - PCI: tegra194: Fix CBB timeout caused by DBI access before core power-on
> - PCI: tegra194: Disable PERST IRQ only in Endpoint mode
>
> I added more context in the commit message for below patch based on review
> comment in V3.
> - PCI: tegra194: Remove IRQF_ONESHOT flag during Endpoint interrupt registration
>
> Rest of the patches are same as the original V3 series, just rebased them on
> 6.19.0-rc6-next.
>
> Verification details.
> - I verified both Root port and Endpoint mode controllers on Tegra234 SoC.
> - Basic sanity Link up, configuration space access and BAR access are verified.
> - I verified that ASPM L1.2 capability is disabled for Endpoint mode.
> - I verified suspend to RAM tests with Endpoint mode.
>
> [1] https://patchwork.kernel.org/project/linux-pci/patch/20221013183854.21087-1-vidyas@nvidia.com/
Thanks for sending this out. It would be great to get all these merged.
The series looks good to me, but I would say that if possible, move all
the known fixes to the start of the series and adding or enabling new
features after the fixes (such as 'Add monitor clock support').
Some of the fixes already have a 'Fixes:' tag but we should add the
fixes tag for others that are also clear fixes.
Thanks
Jon
--
nvpublic
^ permalink raw reply [flat|nested] 33+ messages in thread* Re: [PATCH V4 00/22] Enhancements to pcie-tegra194 driver
2026-01-26 7:44 [PATCH V4 00/22] Enhancements to pcie-tegra194 driver Manikanta Maddireddy
` (22 preceding siblings ...)
2026-02-02 13:35 ` [PATCH V4 00/22] Enhancements to pcie-tegra194 driver Jon Hunter
@ 2026-02-05 7:55 ` Manivannan Sadhasivam
23 siblings, 0 replies; 33+ messages in thread
From: Manivannan Sadhasivam @ 2026-02-05 7:55 UTC (permalink / raw)
To: Manikanta Maddireddy
Cc: bhelgaas, lpieralisi, kwilczynski, robh, krzk+dt, conor+dt,
thierry.reding, jonathanh, jingoohan1, vidyas, cassel,
18255117159, linux-pci, devicetree, linux-tegra, linux-kernel
On Mon, Jan 26, 2026 at 01:14:57PM +0530, Manikanta Maddireddy wrote:
> This series[1] was originally posted by Vidya Sagar, and I have rebased
> it onto 6.19.0-rc6-next. I addressed review comments, reworked a patch
> and included four new patches. I verified these patches on Jetson AGX
> Orin(Tegra234 SoC).
>
> Disabling L1SS capability based on support-clkreq device tree property
> is moved to common DWC driver, so I reworked below patch to disable
> just L1.2 capability on Tegra234 SoC.
> - PCI: tegra194: Disable L1.2 capability of Tegra234 EP
>
> I added below four new patches to fix bugs, commit message of each
> patch has the details on the bug and fix.
> - PCI: tegra194: Add ASPM L1 entrance latency config
> - PCI: tegra194: Use HW version number
> - PCI: tegra194: Fix CBB timeout caused by DBI access before core power-on
> - PCI: tegra194: Disable PERST IRQ only in Endpoint mode
>
Please send the fixes separately. It is hard to review a big series like this. I
don't recommend sending more than 10 patches per series.
- Mani
> I added more context in the commit message for below patch based on review
> comment in V3.
> - PCI: tegra194: Remove IRQF_ONESHOT flag during Endpoint interrupt registration
>
> Rest of the patches are same as the original V3 series, just rebased them on
> 6.19.0-rc6-next.
>
> Verification details.
> - I verified both Root port and Endpoint mode controllers on Tegra234 SoC.
> - Basic sanity Link up, configuration space access and BAR access are verified.
> - I verified that ASPM L1.2 capability is disabled for Endpoint mode.
> - I verified suspend to RAM tests with Endpoint mode.
>
> [1] https://patchwork.kernel.org/project/linux-pci/patch/20221013183854.21087-1-vidyas@nvidia.com/
>
> Manikanta Maddireddy (4):
> PCI: tegra194: Add ASPM L1 entrance latency config
> PCI: tegra194: Use HW version number
> PCI: tegra194: Fix CBB timeout caused by DBI access before core
> power-on
> PCI: tegra194: Disable PERST IRQ only in Endpoint mode
>
> Vidya Sagar (18):
> PCI: tegra194: Use devm_gpiod_get_optional() to parse
> "nvidia,refclk-select"
> PCI: tegra194: Drive CLKREQ signal low explicitly
> PCI: tegra194: Fix polling delay for L2 state
> PCI: tegra194: Apply pinctrl settings for both PCIe RP and EP
> PCI: tegra194: Refactor LTSSM state polling on surprise down
> PCI: tegra194: Disable direct speed change for EP
> PCI: tegra194: Calibrate P2U for endpoint mode
> PCI: tegra194: Free resources during controller deinitialization
> PCI: tegra194: Remove IRQF_ONESHOT flag during Endpoint interrupt
> registration
> PCI: tegra194: Enable DMA interrupt
> PCI: tegra194: Enable hardware hot reset mode in Endpoint
> PCI: tegra194: Allow system suspend when the Endpoint link is not up
> PCI: tegra194: Disable L1.2 capability of Tegra234 EP
> PCI: tegra194: Set LTR message request before PCIe link up
> PCI: tegra194: Don't force the device into the D0 state before L2
> PCI: tegra194: Free up EP resources during remove()
> dt-bindings: PCI: tegra194: Add monitor clock support
> PCI: tegra194: Add core monitor clock support
>
> .../bindings/pci/nvidia,tegra194-pcie-ep.yaml | 6 +-
> .../bindings/pci/nvidia,tegra194-pcie.yaml | 6 +-
> drivers/pci/controller/dwc/pcie-designware.c | 2 +-
> drivers/pci/controller/dwc/pcie-designware.h | 2 +
> drivers/pci/controller/dwc/pcie-tegra194.c | 268 +++++++++++-------
> 5 files changed, 181 insertions(+), 103 deletions(-)
>
> --
> 2.34.1
>
--
மணிவண்ணன் சதாசிவம்
^ permalink raw reply [flat|nested] 33+ messages in thread