* [PATCH v4 1/3] dt-bindings: phy: qcom-edp: Add missing clock for X Elite
2025-10-29 13:31 [PATCH v4 0/3] phy: qcom: edp: Add missing ref clock to x1e80100 Abel Vesa
@ 2025-10-29 13:31 ` Abel Vesa
2025-10-29 16:38 ` Bjorn Andersson
2025-10-29 13:31 ` [PATCH v4 2/3] phy: qcom: edp: Make the number of clocks flexible Abel Vesa
2025-10-29 13:31 ` [PATCH v4 3/3] arm64: dts: qcom: x1e80100: Add missing TCSR ref clock to the DP PHYs Abel Vesa
2 siblings, 1 reply; 9+ messages in thread
From: Abel Vesa @ 2025-10-29 13:31 UTC (permalink / raw)
To: Vinod Koul, Kishon Vijay Abraham I, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Bjorn Andersson,
Dmitry Baryshkov, Konrad Dybcio, Sibi Sankar, Rajendra Nayak
Cc: Neil Armstrong, linux-arm-msm, linux-phy, devicetree,
linux-kernel, Krzysztof Kozlowski, Abel Vesa, Krzysztof Kozlowski,
stable
On X Elite platform, the eDP PHY uses one more clock called ref.
The current X Elite devices supported upstream work fine without this
clock, because the boot firmware leaves this clock enabled. But we should
not rely on that. Also, even though this change breaks the ABI, it is
needed in order to make the driver disables this clock along with the
other ones, for a proper bring-down of the entire PHY.
So attach the this ref clock to the PHY.
Cc: stable@vger.kernel.org # v6.10
Fixes: 5d5607861350 ("dt-bindings: phy: qcom-edp: Add X1E80100 PHY compatibles")
Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Signed-off-by: Abel Vesa <abel.vesa@linaro.org>
---
.../devicetree/bindings/phy/qcom,edp-phy.yaml | 28 +++++++++++++++++++++-
1 file changed, 27 insertions(+), 1 deletion(-)
diff --git a/Documentation/devicetree/bindings/phy/qcom,edp-phy.yaml b/Documentation/devicetree/bindings/phy/qcom,edp-phy.yaml
index eb97181cbb9579893b4ee26a39c3559ad87b2fba..bfc4d75f50ff9e31981fe602478f28320545e52b 100644
--- a/Documentation/devicetree/bindings/phy/qcom,edp-phy.yaml
+++ b/Documentation/devicetree/bindings/phy/qcom,edp-phy.yaml
@@ -37,12 +37,15 @@ properties:
- description: PLL register block
clocks:
- maxItems: 2
+ minItems: 2
+ maxItems: 3
clock-names:
+ minItems: 2
items:
- const: aux
- const: cfg_ahb
+ - const: ref
"#clock-cells":
const: 1
@@ -64,6 +67,29 @@ required:
- "#clock-cells"
- "#phy-cells"
+allOf:
+ - if:
+ properties:
+ compatible:
+ enum:
+ - qcom,x1e80100-dp-phy
+ then:
+ properties:
+ clocks:
+ minItems: 3
+ maxItems: 3
+ clock-names:
+ minItems: 3
+ maxItems: 3
+ else:
+ properties:
+ clocks:
+ minItems: 2
+ maxItems: 2
+ clock-names:
+ minItems: 2
+ maxItems: 2
+
additionalProperties: false
examples:
--
2.48.1
--
linux-phy mailing list
linux-phy@lists.infradead.org
https://lists.infradead.org/mailman/listinfo/linux-phy
^ permalink raw reply related [flat|nested] 9+ messages in thread* Re: [PATCH v4 1/3] dt-bindings: phy: qcom-edp: Add missing clock for X Elite
2025-10-29 13:31 ` [PATCH v4 1/3] dt-bindings: phy: qcom-edp: Add missing clock for X Elite Abel Vesa
@ 2025-10-29 16:38 ` Bjorn Andersson
2025-10-30 14:24 ` Abel Vesa
0 siblings, 1 reply; 9+ messages in thread
From: Bjorn Andersson @ 2025-10-29 16:38 UTC (permalink / raw)
To: Abel Vesa
Cc: Vinod Koul, Kishon Vijay Abraham I, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Dmitry Baryshkov,
Konrad Dybcio, Sibi Sankar, Rajendra Nayak, Neil Armstrong,
linux-arm-msm, linux-phy, devicetree, linux-kernel,
Krzysztof Kozlowski, stable
On Wed, Oct 29, 2025 at 03:31:30PM +0200, Abel Vesa wrote:
> On X Elite platform, the eDP PHY uses one more clock called ref.
>
> The current X Elite devices supported upstream work fine without this
> clock, because the boot firmware leaves this clock enabled. But we should
> not rely on that. Also, even though this change breaks the ABI, it is
> needed in order to make the driver disables this clock along with the
> other ones, for a proper bring-down of the entire PHY.
>
> So attach the this ref clock to the PHY.
>
> Cc: stable@vger.kernel.org # v6.10
> Fixes: 5d5607861350 ("dt-bindings: phy: qcom-edp: Add X1E80100 PHY compatibles")
> Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
> Signed-off-by: Abel Vesa <abel.vesa@linaro.org>
Reviewed-by: Bjorn Andersson <andersson@kernel.org>
> ---
> .../devicetree/bindings/phy/qcom,edp-phy.yaml | 28 +++++++++++++++++++++-
> 1 file changed, 27 insertions(+), 1 deletion(-)
>
> diff --git a/Documentation/devicetree/bindings/phy/qcom,edp-phy.yaml b/Documentation/devicetree/bindings/phy/qcom,edp-phy.yaml
> index eb97181cbb9579893b4ee26a39c3559ad87b2fba..bfc4d75f50ff9e31981fe602478f28320545e52b 100644
> --- a/Documentation/devicetree/bindings/phy/qcom,edp-phy.yaml
> +++ b/Documentation/devicetree/bindings/phy/qcom,edp-phy.yaml
> @@ -37,12 +37,15 @@ properties:
> - description: PLL register block
>
> clocks:
> - maxItems: 2
> + minItems: 2
> + maxItems: 3
>
> clock-names:
> + minItems: 2
> items:
> - const: aux
> - const: cfg_ahb
> + - const: ref
>
> "#clock-cells":
> const: 1
> @@ -64,6 +67,29 @@ required:
> - "#clock-cells"
> - "#phy-cells"
>
> +allOf:
> + - if:
> + properties:
> + compatible:
> + enum:
> + - qcom,x1e80100-dp-phy
Don't we have the refclk on all the other targets as well?
I think we should proceed as you propose here, and if this is the case,
revisit the other targets.
Regards,
Bjorn
> + then:
> + properties:
> + clocks:
> + minItems: 3
> + maxItems: 3
> + clock-names:
> + minItems: 3
> + maxItems: 3
> + else:
> + properties:
> + clocks:
> + minItems: 2
> + maxItems: 2
> + clock-names:
> + minItems: 2
> + maxItems: 2
> +
> additionalProperties: false
>
> examples:
>
> --
> 2.48.1
>
--
linux-phy mailing list
linux-phy@lists.infradead.org
https://lists.infradead.org/mailman/listinfo/linux-phy
^ permalink raw reply [flat|nested] 9+ messages in thread* Re: [PATCH v4 1/3] dt-bindings: phy: qcom-edp: Add missing clock for X Elite
2025-10-29 16:38 ` Bjorn Andersson
@ 2025-10-30 14:24 ` Abel Vesa
0 siblings, 0 replies; 9+ messages in thread
From: Abel Vesa @ 2025-10-30 14:24 UTC (permalink / raw)
To: Bjorn Andersson
Cc: Vinod Koul, Kishon Vijay Abraham I, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Dmitry Baryshkov,
Konrad Dybcio, Sibi Sankar, Rajendra Nayak, Neil Armstrong,
linux-arm-msm, linux-phy, devicetree, linux-kernel,
Krzysztof Kozlowski, stable
On 25-10-29 11:38:53, Bjorn Andersson wrote:
> On Wed, Oct 29, 2025 at 03:31:30PM +0200, Abel Vesa wrote:
> > On X Elite platform, the eDP PHY uses one more clock called ref.
> >
> > The current X Elite devices supported upstream work fine without this
> > clock, because the boot firmware leaves this clock enabled. But we should
> > not rely on that. Also, even though this change breaks the ABI, it is
> > needed in order to make the driver disables this clock along with the
> > other ones, for a proper bring-down of the entire PHY.
> >
> > So attach the this ref clock to the PHY.
> >
> > Cc: stable@vger.kernel.org # v6.10
> > Fixes: 5d5607861350 ("dt-bindings: phy: qcom-edp: Add X1E80100 PHY compatibles")
> > Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
> > Signed-off-by: Abel Vesa <abel.vesa@linaro.org>
>
> Reviewed-by: Bjorn Andersson <andersson@kernel.org>
Thanks.
>
> > ---
> > .../devicetree/bindings/phy/qcom,edp-phy.yaml | 28 +++++++++++++++++++++-
> > 1 file changed, 27 insertions(+), 1 deletion(-)
> >
> > diff --git a/Documentation/devicetree/bindings/phy/qcom,edp-phy.yaml b/Documentation/devicetree/bindings/phy/qcom,edp-phy.yaml
> > index eb97181cbb9579893b4ee26a39c3559ad87b2fba..bfc4d75f50ff9e31981fe602478f28320545e52b 100644
> > --- a/Documentation/devicetree/bindings/phy/qcom,edp-phy.yaml
> > +++ b/Documentation/devicetree/bindings/phy/qcom,edp-phy.yaml
> > @@ -37,12 +37,15 @@ properties:
> > - description: PLL register block
> >
> > clocks:
> > - maxItems: 2
> > + minItems: 2
> > + maxItems: 3
> >
> > clock-names:
> > + minItems: 2
> > items:
> > - const: aux
> > - const: cfg_ahb
> > + - const: ref
> >
> > "#clock-cells":
> > const: 1
> > @@ -64,6 +67,29 @@ required:
> > - "#clock-cells"
> > - "#phy-cells"
> >
> > +allOf:
> > + - if:
> > + properties:
> > + compatible:
> > + enum:
> > + - qcom,x1e80100-dp-phy
>
> Don't we have the refclk on all the other targets as well?
> I think we should proceed as you propose here, and if this is the case,
> revisit the other targets.
So a quick grep suggests that the msm8996 and sc7280 do have and are provided
by the GCC, but they aren't attached to any consumers.
Will check and try to come back with a different patch for those.
--
linux-phy mailing list
linux-phy@lists.infradead.org
https://lists.infradead.org/mailman/listinfo/linux-phy
^ permalink raw reply [flat|nested] 9+ messages in thread
* [PATCH v4 2/3] phy: qcom: edp: Make the number of clocks flexible
2025-10-29 13:31 [PATCH v4 0/3] phy: qcom: edp: Add missing ref clock to x1e80100 Abel Vesa
2025-10-29 13:31 ` [PATCH v4 1/3] dt-bindings: phy: qcom-edp: Add missing clock for X Elite Abel Vesa
@ 2025-10-29 13:31 ` Abel Vesa
2025-10-29 16:42 ` Bjorn Andersson
2025-10-29 13:31 ` [PATCH v4 3/3] arm64: dts: qcom: x1e80100: Add missing TCSR ref clock to the DP PHYs Abel Vesa
2 siblings, 1 reply; 9+ messages in thread
From: Abel Vesa @ 2025-10-29 13:31 UTC (permalink / raw)
To: Vinod Koul, Kishon Vijay Abraham I, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Bjorn Andersson,
Dmitry Baryshkov, Konrad Dybcio, Sibi Sankar, Rajendra Nayak
Cc: Neil Armstrong, linux-arm-msm, linux-phy, devicetree,
linux-kernel, Krzysztof Kozlowski, Abel Vesa, Krzysztof Kozlowski,
stable, Dmitry Baryshkov
On X Elite, the DP PHY needs another clock called ref, while all other
platforms do not.
The current X Elite devices supported upstream work fine without this
clock, because the boot firmware leaves this clock enabled. But we should
not rely on that. Also, even though this change breaks the ABI, it is
needed in order to make the driver disables this clock along with the
other ones, for a proper bring-down of the entire PHY.
So in order to handle these clocks on different platforms, make the driver
get all the clocks regardless of how many there are provided.
Cc: stable@vger.kernel.org # v6.10
Fixes: db83c107dc29 ("phy: qcom: edp: Add v6 specific ops and X1E80100 platform support")
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
Signed-off-by: Abel Vesa <abel.vesa@linaro.org>
---
drivers/phy/qualcomm/phy-qcom-edp.c | 16 ++++++++--------
1 file changed, 8 insertions(+), 8 deletions(-)
diff --git a/drivers/phy/qualcomm/phy-qcom-edp.c b/drivers/phy/qualcomm/phy-qcom-edp.c
index f1b51018683d51df064f60440864c6031638670c..ca9bb9d70e29e1a132bd499fb9f74b5837acf45b 100644
--- a/drivers/phy/qualcomm/phy-qcom-edp.c
+++ b/drivers/phy/qualcomm/phy-qcom-edp.c
@@ -103,7 +103,9 @@ struct qcom_edp {
struct phy_configure_opts_dp dp_opts;
- struct clk_bulk_data clks[2];
+ struct clk_bulk_data *clks;
+ int num_clks;
+
struct regulator_bulk_data supplies[2];
bool is_edp;
@@ -218,7 +220,7 @@ static int qcom_edp_phy_init(struct phy *phy)
if (ret)
return ret;
- ret = clk_bulk_prepare_enable(ARRAY_SIZE(edp->clks), edp->clks);
+ ret = clk_bulk_prepare_enable(edp->num_clks, edp->clks);
if (ret)
goto out_disable_supplies;
@@ -885,7 +887,7 @@ static int qcom_edp_phy_exit(struct phy *phy)
{
struct qcom_edp *edp = phy_get_drvdata(phy);
- clk_bulk_disable_unprepare(ARRAY_SIZE(edp->clks), edp->clks);
+ clk_bulk_disable_unprepare(edp->num_clks, edp->clks);
regulator_bulk_disable(ARRAY_SIZE(edp->supplies), edp->supplies);
return 0;
@@ -1092,11 +1094,9 @@ static int qcom_edp_phy_probe(struct platform_device *pdev)
if (IS_ERR(edp->pll))
return PTR_ERR(edp->pll);
- edp->clks[0].id = "aux";
- edp->clks[1].id = "cfg_ahb";
- ret = devm_clk_bulk_get(dev, ARRAY_SIZE(edp->clks), edp->clks);
- if (ret)
- return ret;
+ edp->num_clks = devm_clk_bulk_get_all(dev, &edp->clks);
+ if (edp->num_clks < 0)
+ return dev_err_probe(dev, edp->num_clks, "failed to parse clocks\n");
edp->supplies[0].supply = "vdda-phy";
edp->supplies[1].supply = "vdda-pll";
--
2.48.1
--
linux-phy mailing list
linux-phy@lists.infradead.org
https://lists.infradead.org/mailman/listinfo/linux-phy
^ permalink raw reply related [flat|nested] 9+ messages in thread* Re: [PATCH v4 2/3] phy: qcom: edp: Make the number of clocks flexible
2025-10-29 13:31 ` [PATCH v4 2/3] phy: qcom: edp: Make the number of clocks flexible Abel Vesa
@ 2025-10-29 16:42 ` Bjorn Andersson
2025-10-30 14:19 ` Abel Vesa
0 siblings, 1 reply; 9+ messages in thread
From: Bjorn Andersson @ 2025-10-29 16:42 UTC (permalink / raw)
To: Abel Vesa
Cc: Vinod Koul, Kishon Vijay Abraham I, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Dmitry Baryshkov,
Konrad Dybcio, Sibi Sankar, Rajendra Nayak, Neil Armstrong,
linux-arm-msm, linux-phy, devicetree, linux-kernel,
Krzysztof Kozlowski, stable, Dmitry Baryshkov
On Wed, Oct 29, 2025 at 03:31:31PM +0200, Abel Vesa wrote:
> On X Elite, the DP PHY needs another clock called ref, while all other
> platforms do not.
>
> The current X Elite devices supported upstream work fine without this
> clock, because the boot firmware leaves this clock enabled. But we should
> not rely on that. Also, even though this change breaks the ABI, it is
> needed in order to make the driver disables this clock along with the
> other ones, for a proper bring-down of the entire PHY.
>
> So in order to handle these clocks on different platforms, make the driver
> get all the clocks regardless of how many there are provided.
>
> Cc: stable@vger.kernel.org # v6.10
> Fixes: db83c107dc29 ("phy: qcom: edp: Add v6 specific ops and X1E80100 platform support")
> Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
> Signed-off-by: Abel Vesa <abel.vesa@linaro.org>
> ---
> drivers/phy/qualcomm/phy-qcom-edp.c | 16 ++++++++--------
> 1 file changed, 8 insertions(+), 8 deletions(-)
>
> diff --git a/drivers/phy/qualcomm/phy-qcom-edp.c b/drivers/phy/qualcomm/phy-qcom-edp.c
> index f1b51018683d51df064f60440864c6031638670c..ca9bb9d70e29e1a132bd499fb9f74b5837acf45b 100644
> --- a/drivers/phy/qualcomm/phy-qcom-edp.c
> +++ b/drivers/phy/qualcomm/phy-qcom-edp.c
> @@ -103,7 +103,9 @@ struct qcom_edp {
>
> struct phy_configure_opts_dp dp_opts;
>
> - struct clk_bulk_data clks[2];
> + struct clk_bulk_data *clks;
> + int num_clks;
> +
> struct regulator_bulk_data supplies[2];
>
> bool is_edp;
> @@ -218,7 +220,7 @@ static int qcom_edp_phy_init(struct phy *phy)
> if (ret)
> return ret;
>
> - ret = clk_bulk_prepare_enable(ARRAY_SIZE(edp->clks), edp->clks);
> + ret = clk_bulk_prepare_enable(edp->num_clks, edp->clks);
> if (ret)
> goto out_disable_supplies;
>
> @@ -885,7 +887,7 @@ static int qcom_edp_phy_exit(struct phy *phy)
> {
> struct qcom_edp *edp = phy_get_drvdata(phy);
>
> - clk_bulk_disable_unprepare(ARRAY_SIZE(edp->clks), edp->clks);
> + clk_bulk_disable_unprepare(edp->num_clks, edp->clks);
> regulator_bulk_disable(ARRAY_SIZE(edp->supplies), edp->supplies);
>
> return 0;
> @@ -1092,11 +1094,9 @@ static int qcom_edp_phy_probe(struct platform_device *pdev)
> if (IS_ERR(edp->pll))
> return PTR_ERR(edp->pll);
>
> - edp->clks[0].id = "aux";
> - edp->clks[1].id = "cfg_ahb";
> - ret = devm_clk_bulk_get(dev, ARRAY_SIZE(edp->clks), edp->clks);
> - if (ret)
> - return ret;
> + edp->num_clks = devm_clk_bulk_get_all(dev, &edp->clks);
> + if (edp->num_clks < 0)
> + return dev_err_probe(dev, edp->num_clks, "failed to parse clocks\n");
Nit...We're not really failing to "parse" clocks...
Reviewed-by: Bjorn Andersson <andersson@kernel.org>
Regards,
Bjorn
>
> edp->supplies[0].supply = "vdda-phy";
> edp->supplies[1].supply = "vdda-pll";
>
> --
> 2.48.1
>
--
linux-phy mailing list
linux-phy@lists.infradead.org
https://lists.infradead.org/mailman/listinfo/linux-phy
^ permalink raw reply [flat|nested] 9+ messages in thread* Re: [PATCH v4 2/3] phy: qcom: edp: Make the number of clocks flexible
2025-10-29 16:42 ` Bjorn Andersson
@ 2025-10-30 14:19 ` Abel Vesa
0 siblings, 0 replies; 9+ messages in thread
From: Abel Vesa @ 2025-10-30 14:19 UTC (permalink / raw)
To: Bjorn Andersson
Cc: Vinod Koul, Kishon Vijay Abraham I, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Dmitry Baryshkov,
Konrad Dybcio, Sibi Sankar, Rajendra Nayak, Neil Armstrong,
linux-arm-msm, linux-phy, devicetree, linux-kernel,
Krzysztof Kozlowski, stable, Dmitry Baryshkov
On 25-10-29 11:42:26, Bjorn Andersson wrote:
> On Wed, Oct 29, 2025 at 03:31:31PM +0200, Abel Vesa wrote:
> > On X Elite, the DP PHY needs another clock called ref, while all other
> > platforms do not.
> >
> > The current X Elite devices supported upstream work fine without this
> > clock, because the boot firmware leaves this clock enabled. But we should
> > not rely on that. Also, even though this change breaks the ABI, it is
> > needed in order to make the driver disables this clock along with the
> > other ones, for a proper bring-down of the entire PHY.
> >
> > So in order to handle these clocks on different platforms, make the driver
> > get all the clocks regardless of how many there are provided.
> >
> > Cc: stable@vger.kernel.org # v6.10
> > Fixes: db83c107dc29 ("phy: qcom: edp: Add v6 specific ops and X1E80100 platform support")
> > Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
> > Signed-off-by: Abel Vesa <abel.vesa@linaro.org>
> > ---
> > drivers/phy/qualcomm/phy-qcom-edp.c | 16 ++++++++--------
> > 1 file changed, 8 insertions(+), 8 deletions(-)
> >
> > diff --git a/drivers/phy/qualcomm/phy-qcom-edp.c b/drivers/phy/qualcomm/phy-qcom-edp.c
> > index f1b51018683d51df064f60440864c6031638670c..ca9bb9d70e29e1a132bd499fb9f74b5837acf45b 100644
> > --- a/drivers/phy/qualcomm/phy-qcom-edp.c
> > +++ b/drivers/phy/qualcomm/phy-qcom-edp.c
> > @@ -103,7 +103,9 @@ struct qcom_edp {
> >
> > struct phy_configure_opts_dp dp_opts;
> >
> > - struct clk_bulk_data clks[2];
> > + struct clk_bulk_data *clks;
> > + int num_clks;
> > +
> > struct regulator_bulk_data supplies[2];
> >
> > bool is_edp;
> > @@ -218,7 +220,7 @@ static int qcom_edp_phy_init(struct phy *phy)
> > if (ret)
> > return ret;
> >
> > - ret = clk_bulk_prepare_enable(ARRAY_SIZE(edp->clks), edp->clks);
> > + ret = clk_bulk_prepare_enable(edp->num_clks, edp->clks);
> > if (ret)
> > goto out_disable_supplies;
> >
> > @@ -885,7 +887,7 @@ static int qcom_edp_phy_exit(struct phy *phy)
> > {
> > struct qcom_edp *edp = phy_get_drvdata(phy);
> >
> > - clk_bulk_disable_unprepare(ARRAY_SIZE(edp->clks), edp->clks);
> > + clk_bulk_disable_unprepare(edp->num_clks, edp->clks);
> > regulator_bulk_disable(ARRAY_SIZE(edp->supplies), edp->supplies);
> >
> > return 0;
> > @@ -1092,11 +1094,9 @@ static int qcom_edp_phy_probe(struct platform_device *pdev)
> > if (IS_ERR(edp->pll))
> > return PTR_ERR(edp->pll);
> >
> > - edp->clks[0].id = "aux";
> > - edp->clks[1].id = "cfg_ahb";
> > - ret = devm_clk_bulk_get(dev, ARRAY_SIZE(edp->clks), edp->clks);
> > - if (ret)
> > - return ret;
> > + edp->num_clks = devm_clk_bulk_get_all(dev, &edp->clks);
> > + if (edp->num_clks < 0)
> > + return dev_err_probe(dev, edp->num_clks, "failed to parse clocks\n");
>
> Nit...We're not really failing to "parse" clocks...
>
Will respin with s/parse/get/
> Reviewed-by: Bjorn Andersson <andersson@kernel.org>
Thanks.
--
linux-phy mailing list
linux-phy@lists.infradead.org
https://lists.infradead.org/mailman/listinfo/linux-phy
^ permalink raw reply [flat|nested] 9+ messages in thread
* [PATCH v4 3/3] arm64: dts: qcom: x1e80100: Add missing TCSR ref clock to the DP PHYs
2025-10-29 13:31 [PATCH v4 0/3] phy: qcom: edp: Add missing ref clock to x1e80100 Abel Vesa
2025-10-29 13:31 ` [PATCH v4 1/3] dt-bindings: phy: qcom-edp: Add missing clock for X Elite Abel Vesa
2025-10-29 13:31 ` [PATCH v4 2/3] phy: qcom: edp: Make the number of clocks flexible Abel Vesa
@ 2025-10-29 13:31 ` Abel Vesa
2025-10-29 16:43 ` Bjorn Andersson
2 siblings, 1 reply; 9+ messages in thread
From: Abel Vesa @ 2025-10-29 13:31 UTC (permalink / raw)
To: Vinod Koul, Kishon Vijay Abraham I, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Bjorn Andersson,
Dmitry Baryshkov, Konrad Dybcio, Sibi Sankar, Rajendra Nayak
Cc: Neil Armstrong, linux-arm-msm, linux-phy, devicetree,
linux-kernel, Krzysztof Kozlowski, Abel Vesa, Krzysztof Kozlowski,
stable
The DP PHYs on X1E80100 need the ref clock which is provided by the
TCSR CC.
The current X Elite devices supported upstream work fine without this
clock, because the boot firmware leaves this clock enabled. But we should
not rely on that. Also, even though this change breaks the ABI, it is
needed in order to make the driver disables this clock along with the
other ones, for a proper bring-down of the entire PHY.
So lets attach it to each of the DP PHYs in order to do that.
Cc: stable@vger.kernel.org # v6.9
Fixes: 1940c25eaa63 ("arm64: dts: qcom: x1e80100: Add display nodes")
Signed-off-by: Abel Vesa <abel.vesa@linaro.org>
---
arch/arm64/boot/dts/qcom/hamoa.dtsi | 12 ++++++++----
1 file changed, 8 insertions(+), 4 deletions(-)
diff --git a/arch/arm64/boot/dts/qcom/hamoa.dtsi b/arch/arm64/boot/dts/qcom/hamoa.dtsi
index a17900eacb20396a9792efcfcd6ce6dd877435d1..59603616a3c229c69467c41e6043c63daa62b46b 100644
--- a/arch/arm64/boot/dts/qcom/hamoa.dtsi
+++ b/arch/arm64/boot/dts/qcom/hamoa.dtsi
@@ -5896,9 +5896,11 @@ mdss_dp2_phy: phy@aec2a00 {
<0 0x0aec2000 0 0x1c8>;
clocks = <&dispcc DISP_CC_MDSS_DPTX2_AUX_CLK>,
- <&dispcc DISP_CC_MDSS_AHB_CLK>;
+ <&dispcc DISP_CC_MDSS_AHB_CLK>,
+ <&tcsr TCSR_EDP_CLKREF_EN>;
clock-names = "aux",
- "cfg_ahb";
+ "cfg_ahb",
+ "ref";
power-domains = <&rpmhpd RPMHPD_MX>;
@@ -5916,9 +5918,11 @@ mdss_dp3_phy: phy@aec5a00 {
<0 0x0aec5000 0 0x1c8>;
clocks = <&dispcc DISP_CC_MDSS_DPTX3_AUX_CLK>,
- <&dispcc DISP_CC_MDSS_AHB_CLK>;
+ <&dispcc DISP_CC_MDSS_AHB_CLK>,
+ <&tcsr TCSR_EDP_CLKREF_EN>;
clock-names = "aux",
- "cfg_ahb";
+ "cfg_ahb",
+ "ref";
power-domains = <&rpmhpd RPMHPD_MX>;
--
2.48.1
--
linux-phy mailing list
linux-phy@lists.infradead.org
https://lists.infradead.org/mailman/listinfo/linux-phy
^ permalink raw reply related [flat|nested] 9+ messages in thread* Re: [PATCH v4 3/3] arm64: dts: qcom: x1e80100: Add missing TCSR ref clock to the DP PHYs
2025-10-29 13:31 ` [PATCH v4 3/3] arm64: dts: qcom: x1e80100: Add missing TCSR ref clock to the DP PHYs Abel Vesa
@ 2025-10-29 16:43 ` Bjorn Andersson
0 siblings, 0 replies; 9+ messages in thread
From: Bjorn Andersson @ 2025-10-29 16:43 UTC (permalink / raw)
To: Abel Vesa
Cc: Vinod Koul, Kishon Vijay Abraham I, Rob Herring,
Krzysztof Kozlowski, Conor Dooley, Dmitry Baryshkov,
Konrad Dybcio, Sibi Sankar, Rajendra Nayak, Neil Armstrong,
linux-arm-msm, linux-phy, devicetree, linux-kernel,
Krzysztof Kozlowski, stable
On Wed, Oct 29, 2025 at 03:31:32PM +0200, Abel Vesa wrote:
> The DP PHYs on X1E80100 need the ref clock which is provided by the
> TCSR CC.
>
> The current X Elite devices supported upstream work fine without this
> clock, because the boot firmware leaves this clock enabled. But we should
> not rely on that. Also, even though this change breaks the ABI, it is
> needed in order to make the driver disables this clock along with the
> other ones, for a proper bring-down of the entire PHY.
>
> So lets attach it to each of the DP PHYs in order to do that.
>
> Cc: stable@vger.kernel.org # v6.9
> Fixes: 1940c25eaa63 ("arm64: dts: qcom: x1e80100: Add display nodes")
Reviewed-by: Bjorn Andersson <andersson@kernel.org>
> Signed-off-by: Abel Vesa <abel.vesa@linaro.org>
> ---
> arch/arm64/boot/dts/qcom/hamoa.dtsi | 12 ++++++++----
> 1 file changed, 8 insertions(+), 4 deletions(-)
>
> diff --git a/arch/arm64/boot/dts/qcom/hamoa.dtsi b/arch/arm64/boot/dts/qcom/hamoa.dtsi
> index a17900eacb20396a9792efcfcd6ce6dd877435d1..59603616a3c229c69467c41e6043c63daa62b46b 100644
> --- a/arch/arm64/boot/dts/qcom/hamoa.dtsi
> +++ b/arch/arm64/boot/dts/qcom/hamoa.dtsi
> @@ -5896,9 +5896,11 @@ mdss_dp2_phy: phy@aec2a00 {
> <0 0x0aec2000 0 0x1c8>;
>
> clocks = <&dispcc DISP_CC_MDSS_DPTX2_AUX_CLK>,
> - <&dispcc DISP_CC_MDSS_AHB_CLK>;
> + <&dispcc DISP_CC_MDSS_AHB_CLK>,
> + <&tcsr TCSR_EDP_CLKREF_EN>;
> clock-names = "aux",
> - "cfg_ahb";
> + "cfg_ahb",
> + "ref";
>
> power-domains = <&rpmhpd RPMHPD_MX>;
>
> @@ -5916,9 +5918,11 @@ mdss_dp3_phy: phy@aec5a00 {
> <0 0x0aec5000 0 0x1c8>;
>
> clocks = <&dispcc DISP_CC_MDSS_DPTX3_AUX_CLK>,
> - <&dispcc DISP_CC_MDSS_AHB_CLK>;
> + <&dispcc DISP_CC_MDSS_AHB_CLK>,
> + <&tcsr TCSR_EDP_CLKREF_EN>;
> clock-names = "aux",
> - "cfg_ahb";
> + "cfg_ahb",
> + "ref";
>
> power-domains = <&rpmhpd RPMHPD_MX>;
>
>
> --
> 2.48.1
>
--
linux-phy mailing list
linux-phy@lists.infradead.org
https://lists.infradead.org/mailman/listinfo/linux-phy
^ permalink raw reply [flat|nested] 9+ messages in thread