* [PATCH 0/2] media: qcom: camss: x1e80100: Add support for individual CSIPHY supplies
@ 2025-04-25 12:01 Bryan O'Donoghue
2025-04-25 12:01 ` [PATCH 1/2] dt-bindings: media: qcom,x1e80100-camss: Fixup csiphy supply names Bryan O'Donoghue
2025-04-25 12:01 ` [PATCH 2/2] media: qcom: camss: x1e80100: Fixup x1e " Bryan O'Donoghue
0 siblings, 2 replies; 4+ messages in thread
From: Bryan O'Donoghue @ 2025-04-25 12:01 UTC (permalink / raw)
To: Robert Foss, Todor Tomov, Mauro Carvalho Chehab, Rob Herring,
Krzysztof Kozlowski, Conor Dooley
Cc: dmitry.baryshkov, loic.poulain, vladimir.zapolskiy, krzk,
linux-arm-msm, linux-media, devicetree, linux-kernel,
Bryan O'Donoghue
In x1e each CSIPHY has its own 0p8 and 1p2 voltage rail. These voltage
rails in previous SoCs were shared between PHYs, over time the hardware
differentiated out the rails per PHY but CAMSS didn't keep-up with or know
about that change.
We have two options to support individual rails per PHY.
- Logical naming of the supply lines
In this case supply names describe the PHY and its expected voltage input
For example vdd-csiphy0-0p8-supply for the 0v8 voltage rail to CSIPHY 0.
- Pin naming of the supply lines
In this case supply names will align to the name of the SoC pin.
For example on x1e the supply name would be vdd vdd-a-csi-0-1-1p2.
This series chooses the first approach for the following reasons:
- Naming coherency across SoCs and PCBs.
Virtually every CSIPHY has 0p8 and 1p2 voltage rails and these are akin
to an architectural feature of these PHYs or at the very least a common
pattern across SoCs.
This means that the pin name on x1e might be VDD_A_CSI_0_1_1P2 and on
qcm2290 VDD_A_CSI_0_1P2 but the yaml standard will be for the regulator
name to be vdd-csiphy0-1p2-supply.
- Accounting for upstreamers who don't have schematic or qcom IP access
Not everybody making upstream submissions has access to schematics or to
Qualcomm's SoC-level pin definitions instead working from
vendor/downstream DT information.
It should still be possible to construct a valid upstream definition from
that downstream DT.
- The counter arugment.
The counter argument is that aligning the pin-names to the regulator
names is less error prone and I agree with that statement.
What I'd say here is - the requirement for CAMSS regulator defintions
in DT at least from my perspective is a putative upstreamer should
be able to show how they have tested a given DT submission.
If that submission isn't tested, it isn't working and should be rejected.
That should then address the concern of having as another example:
vdd-csiphy0-0p8-supply = <&vreg_oops_wrong_regulator>;
I'm promulgating this series in the context of x1e but it should also
unblock qcm2290 and sm8650.
Signed-off-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org>
---
Bryan O'Donoghue (2):
dt-bindings: media: qcom,x1e80100-camss: Fixup csiphy supply names
media: qcom: camss: x1e80100: Fixup x1e csiphy supply names
.../bindings/media/qcom,x1e80100-camss.yaml | 52 +++++++++++++++++-----
drivers/media/platform/qcom/camss/camss.c | 16 +++----
2 files changed, 48 insertions(+), 20 deletions(-)
---
base-commit: 1d1e564fce1bc361af1a1980a7f915a0475a008a
change-id: 20250425-b4-media-committers-25-04-25-camss-supplies-6285c5006da2
Best regards,
--
Bryan O'Donoghue <bryan.odonoghue@linaro.org>
^ permalink raw reply [flat|nested] 4+ messages in thread* [PATCH 1/2] dt-bindings: media: qcom,x1e80100-camss: Fixup csiphy supply names 2025-04-25 12:01 [PATCH 0/2] media: qcom: camss: x1e80100: Add support for individual CSIPHY supplies Bryan O'Donoghue @ 2025-04-25 12:01 ` Bryan O'Donoghue 2025-04-25 13:20 ` Rob Herring (Arm) 2025-04-25 12:01 ` [PATCH 2/2] media: qcom: camss: x1e80100: Fixup x1e " Bryan O'Donoghue 1 sibling, 1 reply; 4+ messages in thread From: Bryan O'Donoghue @ 2025-04-25 12:01 UTC (permalink / raw) To: Robert Foss, Todor Tomov, Mauro Carvalho Chehab, Rob Herring, Krzysztof Kozlowski, Conor Dooley Cc: dmitry.baryshkov, loic.poulain, vladimir.zapolskiy, krzk, linux-arm-msm, linux-media, devicetree, linux-kernel, Bryan O'Donoghue Declare a CSIPHY regulator pair 0p8 and 1p2 for each CSIPHY. Name the inputs based on the voltage so as to have a consistent naming of these rails across SoCs and PCBs. There are no upstream users of this yaml definition yet so this change is safe to make. Signed-off-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org> --- .../bindings/media/qcom,x1e80100-camss.yaml | 52 +++++++++++++++++----- 1 file changed, 40 insertions(+), 12 deletions(-) diff --git a/Documentation/devicetree/bindings/media/qcom,x1e80100-camss.yaml b/Documentation/devicetree/bindings/media/qcom,x1e80100-camss.yaml index 113565cf2a991a8dcbc20889090e177e8bcadaac..c1cc6b275cb2c630e262279f722ce4657cba096f 100644 --- a/Documentation/devicetree/bindings/media/qcom,x1e80100-camss.yaml +++ b/Documentation/devicetree/bindings/media/qcom,x1e80100-camss.yaml @@ -118,14 +118,6 @@ properties: - const: ife1 - const: top - vdd-csiphy-0p8-supply: - description: - Phandle to a 0.8V regulator supply to a PHY. - - vdd-csiphy-1p2-supply: - description: - Phandle to 1.8V regulator supply to a PHY. - ports: $ref: /schemas/graph.yaml#/properties/ports @@ -157,6 +149,30 @@ properties: - clock-lanes - data-lanes + vdd-csiphy0-0p8-supply: + description: Phandle to a 0.8V regulator supply to csiphy0. + + vdd-csiphy0-1p2-supply: + description: Phandle to a 1.2V regulator supply to csiphy0. + + vdd-csiphy1-0p8-supply: + description: Phandle to a 0.8V regulator supply to csiphy1. + + vdd-csiphy1-1p2-supply: + description: Phandle to a 1.2V regulator supply to csiphy1. + + vdd-csiphy2-0p8-supply: + description: Phandle to a 0.8V regulator supply to csiphy2. + + vdd-csiphy2-1p2-supply: + description: Phandle to a 1.2V regulator supply to csiphy2. + + vdd-csiphy4-0p8-supply: + description: Phandle to a 0.8V regulator supply to csiphy4. + + vdd-csiphy4-1p2-supply: + description: Phandle to a 1.2V regulator supply to csiphy4. + required: - compatible - reg @@ -170,10 +186,22 @@ required: - iommus - power-domains - power-domain-names - - vdd-csiphy-0p8-supply - - vdd-csiphy-1p2-supply - ports +anyOf: + - required: + - vdd-csiphy0-0p8-supply + - vdd-csiphy0-1p2-supply + - required: + - vdd-csiphy1-0p8-supply + - vdd-csiphy1-1p2-supply + - required: + - vdd-csiphy2-0p8-supply + - vdd-csiphy2-1p2-supply + - required: + - vdd-csiphy4-0p8-supply + - vdd-csiphy4-1p2-supply + additionalProperties: false examples: @@ -347,8 +375,8 @@ examples: "ife1", "top"; - vdd-csiphy-0p8-supply = <&csiphy_0p8_supply>; - vdd-csiphy-1p2-supply = <&csiphy_1p2_supply>; + vdd-csiphy0-0p8-supply = <&csiphy_0p8_supply>; + vdd-csiphy0-1p2-supply = <&csiphy_1p2_supply>; ports { #address-cells = <1>; -- 2.49.0 ^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH 1/2] dt-bindings: media: qcom,x1e80100-camss: Fixup csiphy supply names 2025-04-25 12:01 ` [PATCH 1/2] dt-bindings: media: qcom,x1e80100-camss: Fixup csiphy supply names Bryan O'Donoghue @ 2025-04-25 13:20 ` Rob Herring (Arm) 0 siblings, 0 replies; 4+ messages in thread From: Rob Herring (Arm) @ 2025-04-25 13:20 UTC (permalink / raw) To: Bryan O'Donoghue Cc: Krzysztof Kozlowski, Mauro Carvalho Chehab, krzk, devicetree, dmitry.baryshkov, linux-kernel, Conor Dooley, Todor Tomov, vladimir.zapolskiy, linux-arm-msm, Robert Foss, linux-media, loic.poulain On Fri, 25 Apr 2025 13:01:51 +0100, Bryan O'Donoghue wrote: > Declare a CSIPHY regulator pair 0p8 and 1p2 for each CSIPHY. > > Name the inputs based on the voltage so as to have a consistent naming of > these rails across SoCs and PCBs. > > There are no upstream users of this yaml definition yet so this change is > safe to make. > > Signed-off-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org> > --- > .../bindings/media/qcom,x1e80100-camss.yaml | 52 +++++++++++++++++----- > 1 file changed, 40 insertions(+), 12 deletions(-) > My bot found errors running 'make dt_binding_check' on your patch: yamllint warnings/errors: ./Documentation/devicetree/bindings/media/qcom,x1e80100-camss.yaml:153:7: [warning] wrong indentation: expected 4 but found 6 (indentation) ./Documentation/devicetree/bindings/media/qcom,x1e80100-camss.yaml:156:7: [warning] wrong indentation: expected 4 but found 6 (indentation) ./Documentation/devicetree/bindings/media/qcom,x1e80100-camss.yaml:159:7: [warning] wrong indentation: expected 4 but found 6 (indentation) ./Documentation/devicetree/bindings/media/qcom,x1e80100-camss.yaml:162:7: [warning] wrong indentation: expected 4 but found 6 (indentation) ./Documentation/devicetree/bindings/media/qcom,x1e80100-camss.yaml:165:7: [warning] wrong indentation: expected 4 but found 6 (indentation) ./Documentation/devicetree/bindings/media/qcom,x1e80100-camss.yaml:168:7: [warning] wrong indentation: expected 4 but found 6 (indentation) ./Documentation/devicetree/bindings/media/qcom,x1e80100-camss.yaml:171:7: [warning] wrong indentation: expected 4 but found 6 (indentation) ./Documentation/devicetree/bindings/media/qcom,x1e80100-camss.yaml:174:7: [warning] wrong indentation: expected 4 but found 6 (indentation) ./Documentation/devicetree/bindings/media/qcom,x1e80100-camss.yaml:193:5: [warning] wrong indentation: expected 6 but found 4 (indentation) ./Documentation/devicetree/bindings/media/qcom,x1e80100-camss.yaml:196:5: [warning] wrong indentation: expected 6 but found 4 (indentation) ./Documentation/devicetree/bindings/media/qcom,x1e80100-camss.yaml:199:5: [warning] wrong indentation: expected 6 but found 4 (indentation) ./Documentation/devicetree/bindings/media/qcom,x1e80100-camss.yaml:202:5: [warning] wrong indentation: expected 6 but found 4 (indentation) dtschema/dtc warnings/errors: doc reference errors (make refcheckdocs): See https://patchwork.ozlabs.org/project/devicetree-bindings/patch/20250425-b4-media-committers-25-04-25-camss-supplies-v1-1-2a3dd3a47a6a@linaro.org 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] 4+ messages in thread
* [PATCH 2/2] media: qcom: camss: x1e80100: Fixup x1e csiphy supply names 2025-04-25 12:01 [PATCH 0/2] media: qcom: camss: x1e80100: Add support for individual CSIPHY supplies Bryan O'Donoghue 2025-04-25 12:01 ` [PATCH 1/2] dt-bindings: media: qcom,x1e80100-camss: Fixup csiphy supply names Bryan O'Donoghue @ 2025-04-25 12:01 ` Bryan O'Donoghue 1 sibling, 0 replies; 4+ messages in thread From: Bryan O'Donoghue @ 2025-04-25 12:01 UTC (permalink / raw) To: Robert Foss, Todor Tomov, Mauro Carvalho Chehab, Rob Herring, Krzysztof Kozlowski, Conor Dooley Cc: dmitry.baryshkov, loic.poulain, vladimir.zapolskiy, krzk, linux-arm-msm, linux-media, devicetree, linux-kernel, Bryan O'Donoghue Amend the names of the csiphy supplies to be specific to each CSIPHY thus allowing for the case where PHYs have individual or shared rails. Signed-off-by: Bryan O'Donoghue <bryan.odonoghue@linaro.org> --- drivers/media/platform/qcom/camss/camss.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/drivers/media/platform/qcom/camss/camss.c b/drivers/media/platform/qcom/camss/camss.c index 06f42875702f02f9d8d83d06ddaa972eacb593f8..d63bc7dc951690132e07ee0fb8df7cef9b66927d 100644 --- a/drivers/media/platform/qcom/camss/camss.c +++ b/drivers/media/platform/qcom/camss/camss.c @@ -2486,8 +2486,8 @@ static const struct resources_icc icc_res_sm8550[] = { static const struct camss_subdev_resources csiphy_res_x1e80100[] = { /* CSIPHY0 */ { - .regulators = { "vdd-csiphy-0p8-supply", - "vdd-csiphy-1p2-supply" }, + .regulators = { "vdd-csiphy0-0p8", + "vdd-csiphy0-1p2" }, .clock = { "csiphy0", "csiphy0_timer" }, .clock_rate = { { 300000000, 400000000, 480000000 }, { 266666667, 400000000 } }, @@ -2501,8 +2501,8 @@ static const struct camss_subdev_resources csiphy_res_x1e80100[] = { }, /* CSIPHY1 */ { - .regulators = { "vdd-csiphy-0p8-supply", - "vdd-csiphy-1p2-supply" }, + .regulators = { "vdd-csiphy1-0p8", + "vdd-csiphy1-1p2" }, .clock = { "csiphy1", "csiphy1_timer" }, .clock_rate = { { 300000000, 400000000, 480000000 }, { 266666667, 400000000 } }, @@ -2516,8 +2516,8 @@ static const struct camss_subdev_resources csiphy_res_x1e80100[] = { }, /* CSIPHY2 */ { - .regulators = { "vdd-csiphy-0p8-supply", - "vdd-csiphy-1p2-supply" }, + .regulators = { "vdd-csiphy2-0p8", + "vdd-csiphy2-1p2" }, .clock = { "csiphy2", "csiphy2_timer" }, .clock_rate = { { 300000000, 400000000, 480000000 }, { 266666667, 400000000 } }, @@ -2531,8 +2531,8 @@ static const struct camss_subdev_resources csiphy_res_x1e80100[] = { }, /* CSIPHY4 */ { - .regulators = { "vdd-csiphy-0p8-supply", - "vdd-csiphy-1p2-supply" }, + .regulators = { "vdd-csiphy4-0p8", + "vdd-csiphy4-1p2" }, .clock = { "csiphy4", "csiphy4_timer" }, .clock_rate = { { 300000000, 400000000, 480000000 }, { 266666667, 400000000 } }, -- 2.49.0 ^ permalink raw reply related [flat|nested] 4+ messages in thread
end of thread, other threads:[~2025-04-25 13:20 UTC | newest] Thread overview: 4+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2025-04-25 12:01 [PATCH 0/2] media: qcom: camss: x1e80100: Add support for individual CSIPHY supplies Bryan O'Donoghue 2025-04-25 12:01 ` [PATCH 1/2] dt-bindings: media: qcom,x1e80100-camss: Fixup csiphy supply names Bryan O'Donoghue 2025-04-25 13:20 ` Rob Herring (Arm) 2025-04-25 12:01 ` [PATCH 2/2] media: qcom: camss: x1e80100: Fixup x1e " Bryan O'Donoghue
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox