* [PATCH 1/4] dt-bindings: phy: qcom,sc8280xp-qmp-pcie-phy: Document the Glymur QMP PCIe PHY
2025-08-19 9:52 [PATCH 0/4] PCI: qcom: Add support for Glymur PCIe Gen5x4 Wenbin Yao
@ 2025-08-19 9:52 ` Wenbin Yao
2025-08-19 12:32 ` Rob Herring (Arm)
2025-08-19 19:42 ` Rob Herring (Arm)
2025-08-19 9:52 ` [PATCH 2/4] dt-bindings: PCI: qcom: Document the Glymur PCIe Controller Wenbin Yao
` (2 subsequent siblings)
3 siblings, 2 replies; 12+ messages in thread
From: Wenbin Yao @ 2025-08-19 9:52 UTC (permalink / raw)
To: Vinod Koul, Kishon Vijay Abraham I, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Bjorn Helgaas,
Lorenzo Pieralisi, Krzysztof Wilczyński,
Manivannan Sadhasivam, Bjorn Andersson
Cc: linux-arm-msm, linux-phy, devicetree, linux-kernel, linux-pci,
Wenbin Yao, konrad.dybcio, qiang.yu, Prudhvi Yarlagadda
From: Prudhvi Yarlagadda <quic_pyarlaga@quicinc.com>
The fifth PCIe instance on Glymur has a Gen5 4-lane PHY. Document it as a
separate compatible.
Signed-off-by: Prudhvi Yarlagadda <quic_pyarlaga@quicinc.com>
Signed-off-by: Wenbin Yao <wenbin.yao@oss.qualcomm.com>
---
Documentation/devicetree/bindings/phy/qcom,sc8280xp-qmp-pcie-phy.yaml | 3 +++
1 file changed, 3 insertions(+)
diff --git a/Documentation/devicetree/bindings/phy/qcom,sc8280xp-qmp-pcie-phy.yaml b/Documentation/devicetree/bindings/phy/qcom,sc8280xp-qmp-pcie-phy.yaml
index b6f140bf5b3b2f79b5c96e591ec0edb76cd45fa5..61e0e2f7ec7f9cb08447e4cd9503698c0a2d383a 100644
--- a/Documentation/devicetree/bindings/phy/qcom,sc8280xp-qmp-pcie-phy.yaml
+++ b/Documentation/devicetree/bindings/phy/qcom,sc8280xp-qmp-pcie-phy.yaml
@@ -16,6 +16,7 @@ description:
properties:
compatible:
enum:
+ - qcom,glymur-qmp-gen5x4-pcie-phy
- qcom,qcs615-qmp-gen3x1-pcie-phy
- qcom,qcs8300-qmp-gen4x2-pcie-phy
- qcom,sa8775p-qmp-gen4x2-pcie-phy
@@ -176,6 +177,7 @@ allOf:
compatible:
contains:
enum:
+ - qcom,glymur-qmp-gen5x4-pcie-phy
- qcom,sa8775p-qmp-gen4x2-pcie-phy
- qcom,sa8775p-qmp-gen4x4-pcie-phy
- qcom,sc8280xp-qmp-gen3x1-pcie-phy
@@ -211,6 +213,7 @@ allOf:
compatible:
contains:
enum:
+ - qcom,glymur-qmp-gen5x4-pcie-phy
- qcom,sm8550-qmp-gen4x2-pcie-phy
- qcom,sm8650-qmp-gen4x2-pcie-phy
- qcom,x1e80100-qmp-gen4x2-pcie-phy
--
2.34.1
^ permalink raw reply related [flat|nested] 12+ messages in thread
* Re: [PATCH 1/4] dt-bindings: phy: qcom,sc8280xp-qmp-pcie-phy: Document the Glymur QMP PCIe PHY
2025-08-19 9:52 ` [PATCH 1/4] dt-bindings: phy: qcom,sc8280xp-qmp-pcie-phy: Document the Glymur QMP PCIe PHY Wenbin Yao
@ 2025-08-19 12:32 ` Rob Herring (Arm)
2025-08-19 19:42 ` Rob Herring (Arm)
1 sibling, 0 replies; 12+ messages in thread
From: Rob Herring (Arm) @ 2025-08-19 12:32 UTC (permalink / raw)
To: Wenbin Yao
Cc: Krzysztof Wilczyński, Bjorn Helgaas, linux-pci,
Kishon Vijay Abraham I, Krzysztof Kozlowski, Conor Dooley,
Lorenzo Pieralisi, konrad.dybcio, linux-kernel,
Prudhvi Yarlagadda, Bjorn Andersson, Manivannan Sadhasivam,
linux-arm-msm, linux-phy, Vinod Koul, devicetree, qiang.yu
On Tue, 19 Aug 2025 02:52:05 -0700, Wenbin Yao wrote:
> From: Prudhvi Yarlagadda <quic_pyarlaga@quicinc.com>
>
> The fifth PCIe instance on Glymur has a Gen5 4-lane PHY. Document it as a
> separate compatible.
>
> Signed-off-by: Prudhvi Yarlagadda <quic_pyarlaga@quicinc.com>
> Signed-off-by: Wenbin Yao <wenbin.yao@oss.qualcomm.com>
> ---
> Documentation/devicetree/bindings/phy/qcom,sc8280xp-qmp-pcie-phy.yaml | 3 +++
> 1 file changed, 3 insertions(+)
>
My bot found errors running 'make dt_binding_check' on your patch:
yamllint warnings/errors:
dtschema/dtc warnings/errors:
doc reference errors (make refcheckdocs):
See https://patchwork.ozlabs.org/project/devicetree-bindings/patch/20250819-glymur_pcie5-v1-1-2ea09f83cbb0@oss.qualcomm.com
The base for the series is generally the latest rc1. A different dependency
should be noted in *this* patch.
If you already ran 'make dt_binding_check' and didn't see the above
error(s), then make sure 'yamllint' is installed and dt-schema is up to
date:
pip3 install dtschema --upgrade
Please check and re-submit after running the above command yourself. Note
that DT_SCHEMA_FILES can be set to your schema file to speed up checking
your schema. However, it must be unset to test all examples with your schema.
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH 1/4] dt-bindings: phy: qcom,sc8280xp-qmp-pcie-phy: Document the Glymur QMP PCIe PHY
2025-08-19 9:52 ` [PATCH 1/4] dt-bindings: phy: qcom,sc8280xp-qmp-pcie-phy: Document the Glymur QMP PCIe PHY Wenbin Yao
2025-08-19 12:32 ` Rob Herring (Arm)
@ 2025-08-19 19:42 ` Rob Herring (Arm)
1 sibling, 0 replies; 12+ messages in thread
From: Rob Herring (Arm) @ 2025-08-19 19:42 UTC (permalink / raw)
To: Wenbin Yao
Cc: Vinod Koul, Conor Dooley, Prudhvi Yarlagadda,
Krzysztof Wilczyński, Bjorn Helgaas, Bjorn Andersson,
linux-phy, linux-kernel, Lorenzo Pieralisi, Manivannan Sadhasivam,
konrad.dybcio, qiang.yu, linux-pci, linux-arm-msm, devicetree,
Kishon Vijay Abraham I, Krzysztof Kozlowski
On Tue, 19 Aug 2025 02:52:05 -0700, Wenbin Yao wrote:
> From: Prudhvi Yarlagadda <quic_pyarlaga@quicinc.com>
>
> The fifth PCIe instance on Glymur has a Gen5 4-lane PHY. Document it as a
> separate compatible.
>
> Signed-off-by: Prudhvi Yarlagadda <quic_pyarlaga@quicinc.com>
> Signed-off-by: Wenbin Yao <wenbin.yao@oss.qualcomm.com>
> ---
> Documentation/devicetree/bindings/phy/qcom,sc8280xp-qmp-pcie-phy.yaml | 3 +++
> 1 file changed, 3 insertions(+)
>
Acked-by: Rob Herring (Arm) <robh@kernel.org>
^ permalink raw reply [flat|nested] 12+ messages in thread
* [PATCH 2/4] dt-bindings: PCI: qcom: Document the Glymur PCIe Controller
2025-08-19 9:52 [PATCH 0/4] PCI: qcom: Add support for Glymur PCIe Gen5x4 Wenbin Yao
2025-08-19 9:52 ` [PATCH 1/4] dt-bindings: phy: qcom,sc8280xp-qmp-pcie-phy: Document the Glymur QMP PCIe PHY Wenbin Yao
@ 2025-08-19 9:52 ` Wenbin Yao
2025-08-19 12:32 ` Rob Herring (Arm)
2025-08-19 19:43 ` Rob Herring (Arm)
2025-08-19 9:52 ` [PATCH 3/4] phy: qcom-qmp: pcs: Add v8.50 register offsets Wenbin Yao
2025-08-19 9:52 ` [PATCH 4/4] phy: qcom: qmp-pcie: Add support for Glymur PCIe Gen5x4 PHY Wenbin Yao
3 siblings, 2 replies; 12+ messages in thread
From: Wenbin Yao @ 2025-08-19 9:52 UTC (permalink / raw)
To: Vinod Koul, Kishon Vijay Abraham I, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Bjorn Helgaas,
Lorenzo Pieralisi, Krzysztof Wilczyński,
Manivannan Sadhasivam, Bjorn Andersson
Cc: linux-arm-msm, linux-phy, devicetree, linux-kernel, linux-pci,
Wenbin Yao, konrad.dybcio, qiang.yu, Prudhvi Yarlagadda
From: Prudhvi Yarlagadda <quic_pyarlaga@quicinc.com>
On the Qualcomm Glymur platform the PCIe host is compatible with the DWC
controller present on the X1E80100 platform. So document the PCIe
controllers found on Glymur and use the X1E80100 compatible string as a
fallback in the schema.
Signed-off-by: Prudhvi Yarlagadda <quic_pyarlaga@quicinc.com>
Signed-off-by: Wenbin Yao <wenbin.yao@oss.qualcomm.com>
---
Documentation/devicetree/bindings/pci/qcom,pcie-x1e80100.yaml | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/Documentation/devicetree/bindings/pci/qcom,pcie-x1e80100.yaml b/Documentation/devicetree/bindings/pci/qcom,pcie-x1e80100.yaml
index 257068a1826492a7071600d03ca0c99babb75bd9..8600f2c74cb81bcb924fa2035d992c3bd147db31 100644
--- a/Documentation/devicetree/bindings/pci/qcom,pcie-x1e80100.yaml
+++ b/Documentation/devicetree/bindings/pci/qcom,pcie-x1e80100.yaml
@@ -16,7 +16,12 @@ description:
properties:
compatible:
- const: qcom,pcie-x1e80100
+ oneOf:
+ - const: qcom,pcie-x1e80100
+ - items:
+ - enum:
+ - qcom,glymur-pcie
+ - const: qcom,pcie-x1e80100
reg:
minItems: 6
--
2.34.1
^ permalink raw reply related [flat|nested] 12+ messages in thread
* Re: [PATCH 2/4] dt-bindings: PCI: qcom: Document the Glymur PCIe Controller
2025-08-19 9:52 ` [PATCH 2/4] dt-bindings: PCI: qcom: Document the Glymur PCIe Controller Wenbin Yao
@ 2025-08-19 12:32 ` Rob Herring (Arm)
2025-08-19 19:43 ` Rob Herring (Arm)
1 sibling, 0 replies; 12+ messages in thread
From: Rob Herring (Arm) @ 2025-08-19 12:32 UTC (permalink / raw)
To: Wenbin Yao
Cc: Manivannan Sadhasivam, linux-pci, devicetree, linux-phy,
Krzysztof Wilczyński, Krzysztof Kozlowski, konrad.dybcio,
Vinod Koul, Lorenzo Pieralisi, Prudhvi Yarlagadda, Conor Dooley,
Bjorn Andersson, linux-arm-msm, Kishon Vijay Abraham I,
Bjorn Helgaas, qiang.yu, linux-kernel
On Tue, 19 Aug 2025 02:52:06 -0700, Wenbin Yao wrote:
> From: Prudhvi Yarlagadda <quic_pyarlaga@quicinc.com>
>
> On the Qualcomm Glymur platform the PCIe host is compatible with the DWC
> controller present on the X1E80100 platform. So document the PCIe
> controllers found on Glymur and use the X1E80100 compatible string as a
> fallback in the schema.
>
> Signed-off-by: Prudhvi Yarlagadda <quic_pyarlaga@quicinc.com>
> Signed-off-by: Wenbin Yao <wenbin.yao@oss.qualcomm.com>
> ---
> Documentation/devicetree/bindings/pci/qcom,pcie-x1e80100.yaml | 7 ++++++-
> 1 file changed, 6 insertions(+), 1 deletion(-)
>
My bot found errors running 'make dt_binding_check' on your patch:
yamllint warnings/errors:
dtschema/dtc warnings/errors:
doc reference errors (make refcheckdocs):
See https://patchwork.ozlabs.org/project/devicetree-bindings/patch/20250819-glymur_pcie5-v1-2-2ea09f83cbb0@oss.qualcomm.com
The base for the series is generally the latest rc1. A different dependency
should be noted in *this* patch.
If you already ran 'make dt_binding_check' and didn't see the above
error(s), then make sure 'yamllint' is installed and dt-schema is up to
date:
pip3 install dtschema --upgrade
Please check and re-submit after running the above command yourself. Note
that DT_SCHEMA_FILES can be set to your schema file to speed up checking
your schema. However, it must be unset to test all examples with your schema.
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH 2/4] dt-bindings: PCI: qcom: Document the Glymur PCIe Controller
2025-08-19 9:52 ` [PATCH 2/4] dt-bindings: PCI: qcom: Document the Glymur PCIe Controller Wenbin Yao
2025-08-19 12:32 ` Rob Herring (Arm)
@ 2025-08-19 19:43 ` Rob Herring (Arm)
1 sibling, 0 replies; 12+ messages in thread
From: Rob Herring (Arm) @ 2025-08-19 19:43 UTC (permalink / raw)
To: Wenbin Yao
Cc: Krzysztof Wilczyński, Bjorn Andersson, konrad.dybcio,
Kishon Vijay Abraham I, linux-arm-msm, linux-phy,
Manivannan Sadhasivam, Lorenzo Pieralisi, devicetree,
Krzysztof Kozlowski, linux-pci, qiang.yu, Prudhvi Yarlagadda,
Bjorn Helgaas, linux-kernel, Conor Dooley, Vinod Koul
On Tue, 19 Aug 2025 02:52:06 -0700, Wenbin Yao wrote:
> From: Prudhvi Yarlagadda <quic_pyarlaga@quicinc.com>
>
> On the Qualcomm Glymur platform the PCIe host is compatible with the DWC
> controller present on the X1E80100 platform. So document the PCIe
> controllers found on Glymur and use the X1E80100 compatible string as a
> fallback in the schema.
>
> Signed-off-by: Prudhvi Yarlagadda <quic_pyarlaga@quicinc.com>
> Signed-off-by: Wenbin Yao <wenbin.yao@oss.qualcomm.com>
> ---
> Documentation/devicetree/bindings/pci/qcom,pcie-x1e80100.yaml | 7 ++++++-
> 1 file changed, 6 insertions(+), 1 deletion(-)
>
Acked-by: Rob Herring (Arm) <robh@kernel.org>
^ permalink raw reply [flat|nested] 12+ messages in thread
* [PATCH 3/4] phy: qcom-qmp: pcs: Add v8.50 register offsets
2025-08-19 9:52 [PATCH 0/4] PCI: qcom: Add support for Glymur PCIe Gen5x4 Wenbin Yao
2025-08-19 9:52 ` [PATCH 1/4] dt-bindings: phy: qcom,sc8280xp-qmp-pcie-phy: Document the Glymur QMP PCIe PHY Wenbin Yao
2025-08-19 9:52 ` [PATCH 2/4] dt-bindings: PCI: qcom: Document the Glymur PCIe Controller Wenbin Yao
@ 2025-08-19 9:52 ` Wenbin Yao
2025-08-19 18:41 ` Dmitry Baryshkov
2025-08-19 9:52 ` [PATCH 4/4] phy: qcom: qmp-pcie: Add support for Glymur PCIe Gen5x4 PHY Wenbin Yao
3 siblings, 1 reply; 12+ messages in thread
From: Wenbin Yao @ 2025-08-19 9:52 UTC (permalink / raw)
To: Vinod Koul, Kishon Vijay Abraham I, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Bjorn Helgaas,
Lorenzo Pieralisi, Krzysztof Wilczyński,
Manivannan Sadhasivam, Bjorn Andersson
Cc: linux-arm-msm, linux-phy, devicetree, linux-kernel, linux-pci,
Wenbin Yao, konrad.dybcio, qiang.yu, Prudhvi Yarlagadda
From: Prudhvi Yarlagadda <quic_pyarlaga@quicinc.com>
The new Glymur SoC bumps up the HW version of QMP phy to v8.50 for PCIE
g5x4. Add the new PCS offsets in a dedicated header file.
Signed-off-by: Prudhvi Yarlagadda <quic_pyarlaga@quicinc.com>
Signed-off-by: Wenbin Yao <wenbin.yao@oss.qualcomm.com>
---
drivers/phy/qualcomm/phy-qcom-qmp-pcs-v8_50.h | 13 +++++++++++++
drivers/phy/qualcomm/phy-qcom-qmp.h | 2 ++
2 files changed, 15 insertions(+)
diff --git a/drivers/phy/qualcomm/phy-qcom-qmp-pcs-v8_50.h b/drivers/phy/qualcomm/phy-qcom-qmp-pcs-v8_50.h
new file mode 100644
index 0000000000000000000000000000000000000000..325c127e8eb7ad842018dce51d09a6ee54ed86ff
--- /dev/null
+++ b/drivers/phy/qualcomm/phy-qcom-qmp-pcs-v8_50.h
@@ -0,0 +1,13 @@
+/* SPDX-License-Identifier: GPL-2.0 */
+/*
+ * Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.
+ */
+
+#ifndef QCOM_PHY_QMP_PCS_V8_50_H_
+#define QCOM_PHY_QMP_PCS_V8_50_H_
+
+#define QPHY_V8_50_PCS_STATUS1 0x010
+#define QPHY_V8_50_PCS_START_CONTROL 0x05c
+#define QPHY_V8_50_PCS_POWER_DOWN_CONTROL 0x64
+
+#endif
diff --git a/drivers/phy/qualcomm/phy-qcom-qmp.h b/drivers/phy/qualcomm/phy-qcom-qmp.h
index f58c82b2dd23e1bda616d67ab7993794b997063b..da2a7ad2cdccef1308a2b7aa71a2e5cf8bd7c1d7 100644
--- a/drivers/phy/qualcomm/phy-qcom-qmp.h
+++ b/drivers/phy/qualcomm/phy-qcom-qmp.h
@@ -58,6 +58,8 @@
#include "phy-qcom-qmp-pcs-v8.h"
+#include "phy-qcom-qmp-pcs-v8_50.h"
+
/* QPHY_SW_RESET bit */
#define SW_RESET BIT(0)
/* QPHY_POWER_DOWN_CONTROL */
--
2.34.1
^ permalink raw reply related [flat|nested] 12+ messages in thread
* Re: [PATCH 3/4] phy: qcom-qmp: pcs: Add v8.50 register offsets
2025-08-19 9:52 ` [PATCH 3/4] phy: qcom-qmp: pcs: Add v8.50 register offsets Wenbin Yao
@ 2025-08-19 18:41 ` Dmitry Baryshkov
0 siblings, 0 replies; 12+ messages in thread
From: Dmitry Baryshkov @ 2025-08-19 18:41 UTC (permalink / raw)
To: Wenbin Yao
Cc: Vinod Koul, Kishon Vijay Abraham I, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Bjorn Helgaas,
Lorenzo Pieralisi, Krzysztof Wilczyński,
Manivannan Sadhasivam, Bjorn Andersson, linux-arm-msm, linux-phy,
devicetree, linux-kernel, linux-pci, konrad.dybcio, qiang.yu,
Prudhvi Yarlagadda
On Tue, Aug 19, 2025 at 02:52:07AM -0700, Wenbin Yao wrote:
> From: Prudhvi Yarlagadda <quic_pyarlaga@quicinc.com>
>
> The new Glymur SoC bumps up the HW version of QMP phy to v8.50 for PCIE
> g5x4. Add the new PCS offsets in a dedicated header file.
>
> Signed-off-by: Prudhvi Yarlagadda <quic_pyarlaga@quicinc.com>
> Signed-off-by: Wenbin Yao <wenbin.yao@oss.qualcomm.com>
> ---
> drivers/phy/qualcomm/phy-qcom-qmp-pcs-v8_50.h | 13 +++++++++++++
> drivers/phy/qualcomm/phy-qcom-qmp.h | 2 ++
> 2 files changed, 15 insertions(+)
>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
--
With best wishes
Dmitry
^ permalink raw reply [flat|nested] 12+ messages in thread
* [PATCH 4/4] phy: qcom: qmp-pcie: Add support for Glymur PCIe Gen5x4 PHY
2025-08-19 9:52 [PATCH 0/4] PCI: qcom: Add support for Glymur PCIe Gen5x4 Wenbin Yao
` (2 preceding siblings ...)
2025-08-19 9:52 ` [PATCH 3/4] phy: qcom-qmp: pcs: Add v8.50 register offsets Wenbin Yao
@ 2025-08-19 9:52 ` Wenbin Yao
2025-08-19 18:43 ` Dmitry Baryshkov
3 siblings, 1 reply; 12+ messages in thread
From: Wenbin Yao @ 2025-08-19 9:52 UTC (permalink / raw)
To: Vinod Koul, Kishon Vijay Abraham I, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Bjorn Helgaas,
Lorenzo Pieralisi, Krzysztof Wilczyński,
Manivannan Sadhasivam, Bjorn Andersson
Cc: linux-arm-msm, linux-phy, devicetree, linux-kernel, linux-pci,
Wenbin Yao, konrad.dybcio, qiang.yu, Prudhvi Yarlagadda
From: Prudhvi Yarlagadda <quic_pyarlaga@quicinc.com>
Add support for Gen5 x4 PCIe QMP PHY found on Glymur platform.
Signed-off-by: Prudhvi Yarlagadda <quic_pyarlaga@quicinc.com>
Signed-off-by: Wenbin Yao <wenbin.yao@oss.qualcomm.com>
---
drivers/phy/qualcomm/phy-qcom-qmp-pcie.c | 29 +++++++++++++++++++++++++++++
1 file changed, 29 insertions(+)
diff --git a/drivers/phy/qualcomm/phy-qcom-qmp-pcie.c b/drivers/phy/qualcomm/phy-qcom-qmp-pcie.c
index 95830dcfdec9b1f68fd55d1cc3c102985cfafcc1..e422cf6932d261074ed3419ed8806e9ed212c26c 100644
--- a/drivers/phy/qualcomm/phy-qcom-qmp-pcie.c
+++ b/drivers/phy/qualcomm/phy-qcom-qmp-pcie.c
@@ -93,6 +93,12 @@ static const unsigned int pciephy_v6_regs_layout[QPHY_LAYOUT_SIZE] = {
[QPHY_PCS_POWER_DOWN_CONTROL] = QPHY_V6_PCS_POWER_DOWN_CONTROL,
};
+static const unsigned int pciephy_v8_50_regs_layout[QPHY_LAYOUT_SIZE] = {
+ [QPHY_START_CTRL] = QPHY_V8_50_PCS_START_CONTROL,
+ [QPHY_PCS_STATUS] = QPHY_V8_50_PCS_STATUS1,
+ [QPHY_PCS_POWER_DOWN_CONTROL] = QPHY_V8_50_PCS_POWER_DOWN_CONTROL,
+};
+
static const struct qmp_phy_init_tbl msm8998_pcie_serdes_tbl[] = {
QMP_PHY_INIT_CFG(QSERDES_V3_COM_BIAS_EN_CLKBUFLR_EN, 0x14),
QMP_PHY_INIT_CFG(QSERDES_V3_COM_CLK_SELECT, 0x30),
@@ -3229,6 +3235,10 @@ static const struct qmp_pcie_offsets qmp_pcie_offsets_v6_30 = {
.ln_shrd = 0x8000,
};
+static const struct qmp_pcie_offsets qmp_pcie_offsets_v8_50 = {
+ .pcs = 0x9000,
+};
+
static const struct qmp_phy_cfg ipq8074_pciephy_cfg = {
.lanes = 1,
@@ -4258,6 +4268,22 @@ static const struct qmp_phy_cfg qmp_v6_gen4x4_pciephy_cfg = {
.phy_status = PHYSTATUS_4_20,
};
+static const struct qmp_phy_cfg glymur_qmp_gen5x4_pciephy_cfg = {
+ .lanes = 4,
+
+ .offsets = &qmp_pcie_offsets_v8_50,
+
+ .reset_list = sdm845_pciephy_reset_l,
+ .num_resets = ARRAY_SIZE(sdm845_pciephy_reset_l),
+ .vreg_list = sm8550_qmp_phy_vreg_l,
+ .num_vregs = ARRAY_SIZE(sm8550_qmp_phy_vreg_l),
+
+ .regs = pciephy_v8_50_regs_layout,
+
+ .pwrdn_ctrl = SW_PWRDN | REFCLK_DRV_DSBL,
+ .phy_status = PHYSTATUS_4_20,
+};
+
static void qmp_pcie_init_port_b(struct qmp_pcie *qmp, const struct qmp_phy_cfg_tbls *tbls)
{
const struct qmp_phy_cfg *cfg = qmp->cfg;
@@ -5114,6 +5140,9 @@ static const struct of_device_id qmp_pcie_of_match_table[] = {
}, {
.compatible = "qcom,x1p42100-qmp-gen4x4-pcie-phy",
.data = &qmp_v6_gen4x4_pciephy_cfg,
+ }, {
+ .compatible = "qcom,glymur-qmp-gen5x4-pcie-phy",
+ .data = &glymur_qmp_gen5x4_pciephy_cfg,
},
{ },
};
--
2.34.1
^ permalink raw reply related [flat|nested] 12+ messages in thread
* Re: [PATCH 4/4] phy: qcom: qmp-pcie: Add support for Glymur PCIe Gen5x4 PHY
2025-08-19 9:52 ` [PATCH 4/4] phy: qcom: qmp-pcie: Add support for Glymur PCIe Gen5x4 PHY Wenbin Yao
@ 2025-08-19 18:43 ` Dmitry Baryshkov
2025-08-20 6:17 ` Wenbin Yao (Consultant)
0 siblings, 1 reply; 12+ messages in thread
From: Dmitry Baryshkov @ 2025-08-19 18:43 UTC (permalink / raw)
To: Wenbin Yao
Cc: Vinod Koul, Kishon Vijay Abraham I, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Bjorn Helgaas,
Lorenzo Pieralisi, Krzysztof Wilczyński,
Manivannan Sadhasivam, Bjorn Andersson, linux-arm-msm, linux-phy,
devicetree, linux-kernel, linux-pci, konrad.dybcio, qiang.yu,
Prudhvi Yarlagadda
On Tue, Aug 19, 2025 at 02:52:08AM -0700, Wenbin Yao wrote:
> From: Prudhvi Yarlagadda <quic_pyarlaga@quicinc.com>
>
> Add support for Gen5 x4 PCIe QMP PHY found on Glymur platform.
>
> Signed-off-by: Prudhvi Yarlagadda <quic_pyarlaga@quicinc.com>
> Signed-off-by: Wenbin Yao <wenbin.yao@oss.qualcomm.com>
> ---
> drivers/phy/qualcomm/phy-qcom-qmp-pcie.c | 29 +++++++++++++++++++++++++++++
> 1 file changed, 29 insertions(+)
>
> diff --git a/drivers/phy/qualcomm/phy-qcom-qmp-pcie.c b/drivers/phy/qualcomm/phy-qcom-qmp-pcie.c
> index 95830dcfdec9b1f68fd55d1cc3c102985cfafcc1..e422cf6932d261074ed3419ed8806e9ed212c26c 100644
> --- a/drivers/phy/qualcomm/phy-qcom-qmp-pcie.c
> +++ b/drivers/phy/qualcomm/phy-qcom-qmp-pcie.c
> @@ -93,6 +93,12 @@ static const unsigned int pciephy_v6_regs_layout[QPHY_LAYOUT_SIZE] = {
> [QPHY_PCS_POWER_DOWN_CONTROL] = QPHY_V6_PCS_POWER_DOWN_CONTROL,
> };
>
> +static const unsigned int pciephy_v8_50_regs_layout[QPHY_LAYOUT_SIZE] = {
> + [QPHY_START_CTRL] = QPHY_V8_50_PCS_START_CONTROL,
> + [QPHY_PCS_STATUS] = QPHY_V8_50_PCS_STATUS1,
> + [QPHY_PCS_POWER_DOWN_CONTROL] = QPHY_V8_50_PCS_POWER_DOWN_CONTROL,
> +};
> +
> static const struct qmp_phy_init_tbl msm8998_pcie_serdes_tbl[] = {
> QMP_PHY_INIT_CFG(QSERDES_V3_COM_BIAS_EN_CLKBUFLR_EN, 0x14),
> QMP_PHY_INIT_CFG(QSERDES_V3_COM_CLK_SELECT, 0x30),
> @@ -3229,6 +3235,10 @@ static const struct qmp_pcie_offsets qmp_pcie_offsets_v6_30 = {
> .ln_shrd = 0x8000,
> };
>
> +static const struct qmp_pcie_offsets qmp_pcie_offsets_v8_50 = {
> + .pcs = 0x9000,
Even if the driver uses only PCS regs for 8.50 currently, I'd suggest
describing the whole picture here. Otherwise it might backfire later, if
we add offsets for other blocks later and they won't match the ones used
for Glymur.
> +};
> +
> static const struct qmp_phy_cfg ipq8074_pciephy_cfg = {
> .lanes = 1,
>
> @@ -4258,6 +4268,22 @@ static const struct qmp_phy_cfg qmp_v6_gen4x4_pciephy_cfg = {
> .phy_status = PHYSTATUS_4_20,
> };
>
> +static const struct qmp_phy_cfg glymur_qmp_gen5x4_pciephy_cfg = {
> + .lanes = 4,
> +
> + .offsets = &qmp_pcie_offsets_v8_50,
> +
> + .reset_list = sdm845_pciephy_reset_l,
> + .num_resets = ARRAY_SIZE(sdm845_pciephy_reset_l),
> + .vreg_list = sm8550_qmp_phy_vreg_l,
> + .num_vregs = ARRAY_SIZE(sm8550_qmp_phy_vreg_l),
> +
> + .regs = pciephy_v8_50_regs_layout,
> +
> + .pwrdn_ctrl = SW_PWRDN | REFCLK_DRV_DSBL,
> + .phy_status = PHYSTATUS_4_20,
> +};
> +
> static void qmp_pcie_init_port_b(struct qmp_pcie *qmp, const struct qmp_phy_cfg_tbls *tbls)
> {
> const struct qmp_phy_cfg *cfg = qmp->cfg;
> @@ -5114,6 +5140,9 @@ static const struct of_device_id qmp_pcie_of_match_table[] = {
> }, {
> .compatible = "qcom,x1p42100-qmp-gen4x4-pcie-phy",
> .data = &qmp_v6_gen4x4_pciephy_cfg,
> + }, {
> + .compatible = "qcom,glymur-qmp-gen5x4-pcie-phy",
> + .data = &glymur_qmp_gen5x4_pciephy_cfg,
> },
> { },
> };
>
> --
> 2.34.1
>
--
With best wishes
Dmitry
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH 4/4] phy: qcom: qmp-pcie: Add support for Glymur PCIe Gen5x4 PHY
2025-08-19 18:43 ` Dmitry Baryshkov
@ 2025-08-20 6:17 ` Wenbin Yao (Consultant)
0 siblings, 0 replies; 12+ messages in thread
From: Wenbin Yao (Consultant) @ 2025-08-20 6:17 UTC (permalink / raw)
To: Dmitry Baryshkov
Cc: Vinod Koul, Kishon Vijay Abraham I, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Bjorn Helgaas,
Lorenzo Pieralisi, Krzysztof Wilczyński,
Manivannan Sadhasivam, Bjorn Andersson, linux-arm-msm, linux-phy,
devicetree, linux-kernel, linux-pci, konrad.dybcio, qiang.yu,
Prudhvi Yarlagadda
On 8/20/2025 2:43 AM, Dmitry Baryshkov wrote:
> On Tue, Aug 19, 2025 at 02:52:08AM -0700, Wenbin Yao wrote:
>> From: Prudhvi Yarlagadda <quic_pyarlaga@quicinc.com>
>>
>> Add support for Gen5 x4 PCIe QMP PHY found on Glymur platform.
>>
>> Signed-off-by: Prudhvi Yarlagadda <quic_pyarlaga@quicinc.com>
>> Signed-off-by: Wenbin Yao <wenbin.yao@oss.qualcomm.com>
>> ---
>> drivers/phy/qualcomm/phy-qcom-qmp-pcie.c | 29 +++++++++++++++++++++++++++++
>> 1 file changed, 29 insertions(+)
>>
>> diff --git a/drivers/phy/qualcomm/phy-qcom-qmp-pcie.c b/drivers/phy/qualcomm/phy-qcom-qmp-pcie.c
>> index 95830dcfdec9b1f68fd55d1cc3c102985cfafcc1..e422cf6932d261074ed3419ed8806e9ed212c26c 100644
>> --- a/drivers/phy/qualcomm/phy-qcom-qmp-pcie.c
>> +++ b/drivers/phy/qualcomm/phy-qcom-qmp-pcie.c
>> @@ -93,6 +93,12 @@ static const unsigned int pciephy_v6_regs_layout[QPHY_LAYOUT_SIZE] = {
>> [QPHY_PCS_POWER_DOWN_CONTROL] = QPHY_V6_PCS_POWER_DOWN_CONTROL,
>> };
>>
>> +static const unsigned int pciephy_v8_50_regs_layout[QPHY_LAYOUT_SIZE] = {
>> + [QPHY_START_CTRL] = QPHY_V8_50_PCS_START_CONTROL,
>> + [QPHY_PCS_STATUS] = QPHY_V8_50_PCS_STATUS1,
>> + [QPHY_PCS_POWER_DOWN_CONTROL] = QPHY_V8_50_PCS_POWER_DOWN_CONTROL,
>> +};
>> +
>> static const struct qmp_phy_init_tbl msm8998_pcie_serdes_tbl[] = {
>> QMP_PHY_INIT_CFG(QSERDES_V3_COM_BIAS_EN_CLKBUFLR_EN, 0x14),
>> QMP_PHY_INIT_CFG(QSERDES_V3_COM_CLK_SELECT, 0x30),
>> @@ -3229,6 +3235,10 @@ static const struct qmp_pcie_offsets qmp_pcie_offsets_v6_30 = {
>> .ln_shrd = 0x8000,
>> };
>>
>> +static const struct qmp_pcie_offsets qmp_pcie_offsets_v8_50 = {
>> + .pcs = 0x9000,
> Even if the driver uses only PCS regs for 8.50 currently, I'd suggest
> describing the whole picture here. Otherwise it might backfire later, if
> we add offsets for other blocks later and they won't match the ones used
> for Glymur.
OK,will add them.
>
>> +};
>> +
>> static const struct qmp_phy_cfg ipq8074_pciephy_cfg = {
>> .lanes = 1,
>>
>> @@ -4258,6 +4268,22 @@ static const struct qmp_phy_cfg qmp_v6_gen4x4_pciephy_cfg = {
>> .phy_status = PHYSTATUS_4_20,
>> };
>>
>> +static const struct qmp_phy_cfg glymur_qmp_gen5x4_pciephy_cfg = {
>> + .lanes = 4,
>> +
>> + .offsets = &qmp_pcie_offsets_v8_50,
>> +
>> + .reset_list = sdm845_pciephy_reset_l,
>> + .num_resets = ARRAY_SIZE(sdm845_pciephy_reset_l),
>> + .vreg_list = sm8550_qmp_phy_vreg_l,
>> + .num_vregs = ARRAY_SIZE(sm8550_qmp_phy_vreg_l),
>> +
>> + .regs = pciephy_v8_50_regs_layout,
>> +
>> + .pwrdn_ctrl = SW_PWRDN | REFCLK_DRV_DSBL,
>> + .phy_status = PHYSTATUS_4_20,
>> +};
>> +
>> static void qmp_pcie_init_port_b(struct qmp_pcie *qmp, const struct qmp_phy_cfg_tbls *tbls)
>> {
>> const struct qmp_phy_cfg *cfg = qmp->cfg;
>> @@ -5114,6 +5140,9 @@ static const struct of_device_id qmp_pcie_of_match_table[] = {
>> }, {
>> .compatible = "qcom,x1p42100-qmp-gen4x4-pcie-phy",
>> .data = &qmp_v6_gen4x4_pciephy_cfg,
>> + }, {
>> + .compatible = "qcom,glymur-qmp-gen5x4-pcie-phy",
>> + .data = &glymur_qmp_gen5x4_pciephy_cfg,
>> },
>> { },
>> };
>>
>> --
>> 2.34.1
>>
--
With best wishes
Wenbin
^ permalink raw reply [flat|nested] 12+ messages in thread