2022-11-25 12:45:43

by Bryan O'Donoghue

[permalink] [raw]
Subject: [PATCH v4 00/18] mdss-dsi-ctrl binding and dts fixes

V4:
- Moves the update of the example from patch #5 to patch #4

V3:
- Moves declaration of mdss-dsi-ctrl into compat string declaration
patch - Krzysztof, Dmitry
- Renames qcm-2290 compat string to agreed compat "qcom,socname-dsi-ctrl"
Dmirty, Krzysztof
- Adds empty line after if clause in yaml control flow section - Dmirty
- Adds Rb/Ack - Krzysztof, Dmitry, Doug, David
- vdd*
Looking into this some more, I don't believe vdd, vdda, vddio ought to be
required properties. Its up to the PCB manufacturer and the panel in-use
how that panel is powered. Powering the panel is not something that
even necessarily needs to be done from the dsi-ctrl driver.
Originally marking vdd* as required in the .txt was an error, its not a
SoC level dtsi requirement.
- clock-names
Rather than replicate the clock-name in each if block I listed them with
a specific description from a similar reference in usb/qcom,dwc3.yaml.

https://lore.kernel.org/linux-arm-msm/[email protected]/

V2:
https://www.spinics.net/lists/linux-arm-msm/msg116326.html

- Moves the DSI PHY changes to a different later series.
There are enough dsi-controller-main changes to justify its own
standalone series.

- The original phy-name binding change given discussion with Rob and
Krzysztof became its own standalone series that has since been merged.
https://www.mail-archive.com/[email protected]/msg403214.html

- Retains the drop of power-domain from yaml as a required property.
I dug into the available dtsi. The apq8064 doesn't appear to have any
GDSC which can be attached as a power-domain, which means the
power-domain requirement is not universal across the various silicon
versions.

- Adds Dmitry's RB to power-domain drop

- For the clock declarations I've
* I noticed that the simple change I had worked for msm8939 but
subsquently broke other dtsi which drove a bigger change to document
the clocks on a per compatible basis.
* Added compat strings in yaml.
* Moved the allOf down later in the file to acomodate the if/then.
* Number of clocks validated on a per compatible basis
* The driver code which doesn't care about the number of clocks
can still operate on the mdss-dsi-ctrl compat but the dts checks will
validate against the compat string and yaml.

- vdd descriptions
Took the previous text I missed from the .txt file - Krzysztof, Dmitry
Adds vdd, vdda and vddio to the required list. This exposes warnings in
existing dtsi but the previous .txt declared these regulators as
required. - Krzysztof

V1:
This series fixes up a number of dtbs checks which are being flagged adding
in the msm8939 dtsi.


When converting from .txt to .yaml a number of the parameters for the older
msm8916 silicon were not transmitted into the yaml.

Adding in the msm8939 which is a near 1:1 copy of the msm8916 in terms of
dtsi triggers a rake of dtbs checks as a result.

https://www.mail-archive.com/[email protected]/msg403211.html

Bryan O'Donoghue (18):
dt-bindings: msm: dsi-controller-main: Fix operating-points-v2
constraint
dt-bindings: msm: dsi-controller-main: Fix power-domain constraint
dt-bindings: msm: dsi-controller-main: Rename qcom,dsi-ctrl-6g-qcm2290
to qcom,qcm2290-dsi-ctrl
dt-bindings: msm: dsi-controller-main: Add compatible strings for
every current SoC
dt-bindings: msm: dsi-controller-main: Document clocks on a per
compatible basis
dt-bindings: msm: dsi-controller-main: Fix description of core clock
dt-bindings: msm: dsi-controller-main: Fix clock declarations
dt-bindings: msm: dsi-controller-main: Add vdd* descriptions back in
ARM: dts: qcom: apq8064: add compat qcom,apq8064-dsi-ctrl
ARM: dts: qcom: msm8974: Add compat qcom,msm8974-dsi-ctrl
arm64: dts: qcom: msm8916: Add compat qcom,msm8916-dsi-ctrl
arm64: dts: qcom: msm8996: Add compat qcom,msm8996-dsi-ctrl
arm64: dts: qcom: sc7180: Add compat qcom,sc7180-dsi-ctrl
arm64: dts: qcom: sc7280: Add compat qcom,sc7280-dsi-ctrl
arm64: dts: qcom: sdm630: Add compat qcom,sdm630-dsi-ctrl
arm64: dts: qcom: sdm660: Add compat qcom,sdm660-dsi-ctrl
arm64: dts: qcom: sdm845: Add compat qcom,sdm845-dsi-ctrl
arm64: dts: qcom: sm8250: Add compat qcom,sm8250-dsi-ctrl

.../display/msm/dsi-controller-main.yaml | 205 ++++++++++++++++--
arch/arm/boot/dts/qcom-apq8064.dtsi | 3 +-
arch/arm/boot/dts/qcom-msm8974.dtsi | 3 +-
arch/arm64/boot/dts/qcom/msm8916.dtsi | 3 +-
arch/arm64/boot/dts/qcom/msm8996.dtsi | 6 +-
arch/arm64/boot/dts/qcom/sc7180.dtsi | 3 +-
arch/arm64/boot/dts/qcom/sc7280.dtsi | 3 +-
arch/arm64/boot/dts/qcom/sdm630.dtsi | 3 +-
arch/arm64/boot/dts/qcom/sdm660.dtsi | 3 +-
arch/arm64/boot/dts/qcom/sdm845.dtsi | 6 +-
arch/arm64/boot/dts/qcom/sm8250.dtsi | 6 +-
11 files changed, 208 insertions(+), 36 deletions(-)

--
2.38.1


2022-11-25 12:46:09

by Bryan O'Donoghue

[permalink] [raw]
Subject: [PATCH v4 06/18] dt-bindings: msm: dsi-controller-main: Fix description of core clock

There's a typo in describing the core clock as an 'escape' clock. The
accurate description is 'core'.

Fixes: 4dbe55c97741 ("dt-bindings: msm: dsi: add yaml schemas for DSI bindings")
Reviewed-by: Dmitry Baryshkov <[email protected]>
Acked-by: Krzysztof Kozlowski <[email protected]>
Signed-off-by: Bryan O'Donoghue <[email protected]>
---
.../devicetree/bindings/display/msm/dsi-controller-main.yaml | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml b/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
index 88aac7d33555c..0c09b9230b7f5 100644
--- a/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
+++ b/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
@@ -40,7 +40,7 @@ properties:
- description: Display byte clock
- description: Display byte interface clock
- description: Display pixel clock
- - description: Display escape clock
+ - description: Display core clock
- description: Display AHB clock
- description: Display AXI clock

--
2.38.1

2022-11-25 12:46:47

by Bryan O'Donoghue

[permalink] [raw]
Subject: [PATCH v4 07/18] dt-bindings: msm: dsi-controller-main: Fix clock declarations

When converting from .txt to .yaml dt-binding descriptions we appear to
have missed some of the previous detail on the number and names of
permissible clocks.

Fix this by listing the clock descriptions against the clock names at a
high level.

Fixes: 4dbe55c97741 ("dt-bindings: msm: dsi: add yaml schemas for DSI bindings")
Signed-off-by: Bryan O'Donoghue <[email protected]>
---
.../display/msm/dsi-controller-main.yaml | 20 ++++++++++++-------
1 file changed, 13 insertions(+), 7 deletions(-)

diff --git a/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml b/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
index 0c09b9230b7f5..0fbb0c04f4b06 100644
--- a/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
+++ b/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
@@ -36,13 +36,19 @@ properties:
maxItems: 1

clocks:
- items:
- - description: Display byte clock
- - description: Display byte interface clock
- - description: Display pixel clock
- - description: Display core clock
- - description: Display AHB clock
- - description: Display AXI clock
+ description: |
+ Several clocks are used, depending on the variant. Typical ones are::
+ - bus:: Display AHB clock.
+ - byte:: Display byte clock.
+ - byte_intf:: Display byte interface clock.
+ - core:: Display core clock.
+ - core_mss:: Core MultiMedia SubSystem clock.
+ - iface:: Display AXI clock.
+ - mdp_core:: MDP Core clock.
+ - mnoc:: MNOC clock
+ - pixel:: Display pixel clock.
+ minItems: 6
+ maxItems: 9

clock-names:
minItems: 6
--
2.38.1

2022-11-25 12:47:21

by Bryan O'Donoghue

[permalink] [raw]
Subject: [PATCH v4 03/18] dt-bindings: msm: dsi-controller-main: Rename qcom,dsi-ctrl-6g-qcm2290 to qcom,qcm2290-dsi-ctrl

We will add in a number of compat strings to dsi-controller-main.yaml in
the format "qcom,socname-dsi-ctrl" convert the currently unused
qcom,dsi-ctrl-6g-qcm2290 to qcom,qcm2290-dsi-ctrl.

Signed-off-by: Bryan O'Donoghue <[email protected]>
---
.../devicetree/bindings/display/msm/dsi-controller-main.yaml | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml b/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
index cf782c5f5bdb0..67d08dc338925 100644
--- a/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
+++ b/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
@@ -16,7 +16,7 @@ properties:
compatible:
enum:
- qcom,mdss-dsi-ctrl
- - qcom,dsi-ctrl-6g-qcm2290
+ - qcom,qcm2290-dsi-ctrl

reg:
maxItems: 1
--
2.38.1

2022-11-25 12:48:32

by Bryan O'Donoghue

[permalink] [raw]
Subject: [PATCH v4 01/18] dt-bindings: msm: dsi-controller-main: Fix operating-points-v2 constraint

The existing msm8916.dtsi does not depend on nor require operating points.

Fixes: 4dbe55c97741 ("dt-bindings: msm: dsi: add yaml schemas for DSI bindings")
Reviewed-by: Dmitry Baryshkov <[email protected]>
Acked-by: Krzysztof Kozlowski <[email protected]>
Signed-off-by: Bryan O'Donoghue <[email protected]>
---
.../devicetree/bindings/display/msm/dsi-controller-main.yaml | 1 -
1 file changed, 1 deletion(-)

diff --git a/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml b/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
index 7782bff89afc7..27ebfd5ffb22f 100644
--- a/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
+++ b/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
@@ -135,7 +135,6 @@ required:
- assigned-clocks
- assigned-clock-parents
- power-domains
- - operating-points-v2
- ports

additionalProperties: false
--
2.38.1

2022-11-25 12:49:49

by Bryan O'Donoghue

[permalink] [raw]
Subject: [PATCH v4 15/18] arm64: dts: qcom: sdm630: Add compat qcom,sdm630-dsi-ctrl

Add silicon specific compatible qcom,sdm630-dsi-ctrl to the
mdss-dsi-ctrl block. This allows us to differentiate the specific bindings
for sdm630 against the yaml documentation.

Signed-off-by: Bryan O'Donoghue <[email protected]>
---
arch/arm64/boot/dts/qcom/sdm630.dtsi | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/arch/arm64/boot/dts/qcom/sdm630.dtsi b/arch/arm64/boot/dts/qcom/sdm630.dtsi
index 0e7764f66b104..905ddb57318dd 100644
--- a/arch/arm64/boot/dts/qcom/sdm630.dtsi
+++ b/arch/arm64/boot/dts/qcom/sdm630.dtsi
@@ -1581,7 +1581,8 @@ opp-412500000 {
};

dsi0: dsi@c994000 {
- compatible = "qcom,mdss-dsi-ctrl";
+ compatible = "qcom,sdm630-dsi-ctrl",
+ "qcom,mdss-dsi-ctrl";
reg = <0x0c994000 0x400>;
reg-names = "dsi_ctrl";

--
2.38.1

2022-11-25 12:50:49

by Bryan O'Donoghue

[permalink] [raw]
Subject: [PATCH v4 18/18] arm64: dts: qcom: sm8250: Add compat qcom,sm8250-dsi-ctrl

Add silicon specific compatible qcom,sm8250-dsi-ctrl to the
mdss-dsi-ctrl block. This allows us to differentiate the specific bindings
for sm8250 against the yaml documentation.

Signed-off-by: Bryan O'Donoghue <[email protected]>
---
arch/arm64/boot/dts/qcom/sm8250.dtsi | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/arch/arm64/boot/dts/qcom/sm8250.dtsi b/arch/arm64/boot/dts/qcom/sm8250.dtsi
index 0d47c5b7148e1..8a73f1b487043 100644
--- a/arch/arm64/boot/dts/qcom/sm8250.dtsi
+++ b/arch/arm64/boot/dts/qcom/sm8250.dtsi
@@ -3528,7 +3528,8 @@ opp-460000000 {
};

dsi0: dsi@ae94000 {
- compatible = "qcom,mdss-dsi-ctrl";
+ compatible = "qcom,sm8250-dsi-ctrl",
+ "qcom,mdss-dsi-ctrl";
reg = <0 0x0ae94000 0 0x400>;
reg-names = "dsi_ctrl";

@@ -3619,7 +3620,8 @@ dsi0_phy: dsi-phy@ae94400 {
};

dsi1: dsi@ae96000 {
- compatible = "qcom,mdss-dsi-ctrl";
+ compatible = "qcom,sm8250-dsi-ctrl",
+ "qcom,mdss-dsi-ctrl";
reg = <0 0x0ae96000 0 0x400>;
reg-names = "dsi_ctrl";

--
2.38.1

2022-11-25 12:54:08

by Bryan O'Donoghue

[permalink] [raw]
Subject: [PATCH v4 11/18] arm64: dts: qcom: msm8916: Add compat qcom,msm8916-dsi-ctrl

Add silicon specific compatible qcom,msm8916-dsi-ctrl to the
mdss-dsi-ctrl block. This allows us to differentiate the specific bindings
for msm8916 against the yaml documentation.

Signed-off-by: Bryan O'Donoghue <[email protected]>
---
arch/arm64/boot/dts/qcom/msm8916.dtsi | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/arch/arm64/boot/dts/qcom/msm8916.dtsi b/arch/arm64/boot/dts/qcom/msm8916.dtsi
index c1d8a1b388d27..20e72038cadfe 100644
--- a/arch/arm64/boot/dts/qcom/msm8916.dtsi
+++ b/arch/arm64/boot/dts/qcom/msm8916.dtsi
@@ -1021,7 +1021,8 @@ mdp5_intf1_out: endpoint {
};

dsi0: dsi@1a98000 {
- compatible = "qcom,mdss-dsi-ctrl";
+ compatible = "qcom,msm8916-dsi-ctrl",
+ "qcom,mdss-dsi-ctrl";
reg = <0x01a98000 0x25c>;
reg-names = "dsi_ctrl";

--
2.38.1

2022-11-25 13:06:04

by Bryan O'Donoghue

[permalink] [raw]
Subject: [PATCH v4 02/18] dt-bindings: msm: dsi-controller-main: Fix power-domain constraint

power-domain is required for the sc7180 dispcc GDSC but not every qcom SoC
has a similar dependency for example the aqp8064.

Most Qcom SoC's using mdss-dsi-ctrl seem to have the ability to
power-collapse the MDP without collapsing DSI.

For example the qcom vendor kernel commit for apq8084, msm8226, msm8916,
msm8974.

https://review.carbonrom.org/plugins/gitiles/CarbonROM/android_kernel_oneplus_msm8994/+/7b5c011a770daa2811778937ed646237a28a8694

"ARM: dts: msm: add mdss gdsc supply to dsi controller device

It is possible for the DSI controller to be active when MDP is
power collapsed. DSI controller needs to have it's own vote for
mdss gdsc to ensure that gdsc remains on in such cases."

This however doesn't appear to be the case for the apq8064 so we shouldn't
be marking power-domain as required in yaml checks.

Fixes: 4dbe55c97741 ("dt-bindings: msm: dsi: add yaml schemas for DSI bindings")
Reviewed-by: Dmitry Baryshkov <[email protected]>
Acked-by: Krzysztof Kozlowski <[email protected]>
Signed-off-by: Bryan O'Donoghue <[email protected]>
---
.../devicetree/bindings/display/msm/dsi-controller-main.yaml | 1 -
1 file changed, 1 deletion(-)

diff --git a/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml b/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
index 27ebfd5ffb22f..cf782c5f5bdb0 100644
--- a/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
+++ b/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
@@ -134,7 +134,6 @@ required:
- phys
- assigned-clocks
- assigned-clock-parents
- - power-domains
- ports

additionalProperties: false
--
2.38.1

2022-11-25 13:07:09

by Bryan O'Donoghue

[permalink] [raw]
Subject: [PATCH v4 16/18] arm64: dts: qcom: sdm660: Add compat qcom,sdm660-dsi-ctrl

Add silicon specific compatible qcom,sdm660-dsi-ctrl to the
mdss-dsi-ctrl block. This allows us to differentiate the specific bindings
for sdm660 against the yaml documentation.

Signed-off-by: Bryan O'Donoghue <[email protected]>
---
arch/arm64/boot/dts/qcom/sdm660.dtsi | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/arch/arm64/boot/dts/qcom/sdm660.dtsi b/arch/arm64/boot/dts/qcom/sdm660.dtsi
index 10bf1c45cf6ec..f8ec728e67f3d 100644
--- a/arch/arm64/boot/dts/qcom/sdm660.dtsi
+++ b/arch/arm64/boot/dts/qcom/sdm660.dtsi
@@ -154,7 +154,8 @@ mdp5_intf2_out: endpoint {

&mdss {
dsi1: dsi@c996000 {
- compatible = "qcom,mdss-dsi-ctrl";
+ compatible = "qcom,sdm660-dsi-ctrl",
+ "qcom,mdss-dsi-ctrl";
reg = <0x0c996000 0x400>;
reg-names = "dsi_ctrl";

--
2.38.1

2022-11-25 13:09:59

by Bryan O'Donoghue

[permalink] [raw]
Subject: [PATCH v4 17/18] arm64: dts: qcom: sdm845: Add compat qcom,sdm845-dsi-ctrl

Add silicon specific compatible qcom,sdm845-dsi-ctrl to the
mdss-dsi-ctrl block. This allows us to differentiate the specific bindings
for sdm845 against the yaml documentation.

Reviewed-by: Douglas Anderson <[email protected]>
Signed-off-by: Bryan O'Donoghue <[email protected]>
---
arch/arm64/boot/dts/qcom/sdm845.dtsi | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/arch/arm64/boot/dts/qcom/sdm845.dtsi b/arch/arm64/boot/dts/qcom/sdm845.dtsi
index 5420205417c81..c14e49c9655c3 100644
--- a/arch/arm64/boot/dts/qcom/sdm845.dtsi
+++ b/arch/arm64/boot/dts/qcom/sdm845.dtsi
@@ -4522,7 +4522,8 @@ opp-430000000 {
};

dsi0: dsi@ae94000 {
- compatible = "qcom,mdss-dsi-ctrl";
+ compatible = "qcom,sdm845-dsi-ctrl",
+ "qcom,mdss-dsi-ctrl";
reg = <0 0x0ae94000 0 0x400>;
reg-names = "dsi_ctrl";

@@ -4593,7 +4594,8 @@ dsi0_phy: dsi-phy@ae94400 {
};

dsi1: dsi@ae96000 {
- compatible = "qcom,mdss-dsi-ctrl";
+ compatible = "qcom,sdm845-dsi-ctrl",
+ "qcom,mdss-dsi-ctrl";
reg = <0 0x0ae96000 0 0x400>;
reg-names = "dsi_ctrl";

--
2.38.1

2022-11-25 13:10:41

by Bryan O'Donoghue

[permalink] [raw]
Subject: [PATCH v4 05/18] dt-bindings: msm: dsi-controller-main: Document clocks on a per compatible basis

Each compatible has a different set of clocks which are associated with it.
Add in the list of clocks for each compatible.

Signed-off-by: Bryan O'Donoghue <[email protected]>
---
.../display/msm/dsi-controller-main.yaml | 152 ++++++++++++++++--
1 file changed, 142 insertions(+), 10 deletions(-)

diff --git a/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml b/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
index 0cd2079137b02..88aac7d33555c 100644
--- a/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
+++ b/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
@@ -9,9 +9,6 @@ title: Qualcomm Display DSI controller
maintainers:
- Krishna Manikandan <[email protected]>

-allOf:
- - $ref: "../dsi-controller.yaml#"
-
properties:
compatible:
items:
@@ -48,13 +45,8 @@ properties:
- description: Display AXI clock

clock-names:
- items:
- - const: byte
- - const: byte_intf
- - const: pixel
- - const: core
- - const: iface
- - const: bus
+ minItems: 6
+ maxItems: 9

phys:
maxItems: 1
@@ -147,6 +139,146 @@ required:
- assigned-clock-parents
- ports

+allOf:
+ - $ref: "../dsi-controller.yaml#"
+ - if:
+ properties:
+ compatible:
+ contains:
+ enum:
+ - qcom,apq8064-dsi-ctrl
+ then:
+ properties:
+ clocks:
+ maxItems: 7
+ clock-names:
+ items:
+ - const: iface
+ - const: bus
+ - const: core_mmss
+ - const: src
+ - const: byte
+ - const: pixel
+ - const: core
+
+ - if:
+ properties:
+ compatible:
+ contains:
+ enum:
+ - qcom,msm8916-dsi-ctrl
+ then:
+ properties:
+ clocks:
+ maxItems: 6
+ clock-names:
+ items:
+ - const: mdp_core
+ - const: iface
+ - const: bus
+ - const: byte
+ - const: pixel
+ - const: core
+
+ - if:
+ properties:
+ compatible:
+ contains:
+ enum:
+ - qcom,msm8974-dsi-ctrl
+ then:
+ properties:
+ clocks:
+ maxItems: 3
+ clock-names:
+ items:
+ - const: iface
+ - const: bus
+ - const: vsync
+
+ - if:
+ properties:
+ compatible:
+ contains:
+ enum:
+ - qcom,msm8996-dsi-ctrl
+ then:
+ properties:
+ clocks:
+ maxItems: 7
+ clock-names:
+ items:
+ - const: mdp_core
+ - const: byte
+ - const: iface
+ - const: bus
+ - const: core_mmss
+ - const: pixel
+ - const: core
+
+ - if:
+ properties:
+ compatible:
+ contains:
+ enum:
+ - qcom,sc7180-dsi-ctrl
+ - qcom,sc7280-dsi-ctrl
+ - qcom,sm8250-dsi-ctrl
+ then:
+ properties:
+ clocks:
+ maxItems: 6
+ clock-names:
+ items:
+ - const: byte
+ - const: byte_intf
+ - const: pixel
+ - const: core
+ - const: iface
+ - const: bus
+
+ - if:
+ properties:
+ compatible:
+ contains:
+ enum:
+ - qcom,sdm630-dsi-ctrl
+ - qcom,sdm660-dsi-ctrl
+ then:
+ properties:
+ clocks:
+ maxItems: 9
+ clock-names:
+ items:
+ - const: mdp_core
+ - const: byte
+ - const: byte_intf
+ - const: mnoc
+ - const: iface
+ - const: bus
+ - const: core_mmss
+ - const: pixel
+ - const: core
+
+ - if:
+ properties:
+ compatible:
+ contains:
+ enum:
+ - qcom,sdm845-dsi-ctrl
+ then:
+ properties:
+ clocks:
+ maxItems: 6
+ clock-names:
+ items:
+ - const: byte
+ - const: byte_intf
+ - const: pixel
+ - const: core
+ - const: iface
+ - const: bus
+
additionalProperties: false

examples:
--
2.38.1

2022-11-25 13:19:30

by Bryan O'Donoghue

[permalink] [raw]
Subject: [PATCH v4 04/18] dt-bindings: msm: dsi-controller-main: Add compatible strings for every current SoC

Currently we do not differentiate between the various users of the
qcom,mdss-dsi-ctrl. The driver is flexible enough to operate from one
compatible string but, the hardware does have some significant differences
in the number of clocks.

To facilitate documenting the clocks add the following compatible strings

- qcom,apq8064-dsi-ctrl
- qcom,msm8916-dsi-ctrl
- qcom,msm8974-dsi-ctrl
- qcom,msm8996-dsi-ctrl
- qcom,sc7180-dsi-ctrl
- qcom,sc7280-dsi-ctrl
- qcom,sdm630-dsi-ctrl
- qcom,sdm660-dsi-ctrl
- qcom,sdm845-dsi-ctrl
- qcom,sm8250-dsi-ctrl

Each SoC dtsi should declare "qcom,socname-dsi-ctrl", "qcom,mdss-dsi-ctrl";

Signed-off-by: Bryan O'Donoghue <[email protected]>
---
.../display/msm/dsi-controller-main.yaml | 19 +++++++++++++++----
1 file changed, 15 insertions(+), 4 deletions(-)

diff --git a/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml b/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
index 67d08dc338925..0cd2079137b02 100644
--- a/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
+++ b/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
@@ -14,9 +14,20 @@ allOf:

properties:
compatible:
- enum:
- - qcom,mdss-dsi-ctrl
- - qcom,qcm2290-dsi-ctrl
+ items:
+ - enum:
+ - qcom,apq8064-dsi-ctrl
+ - qcom,msm8916-dsi-ctrl
+ - qcom,msm8974-dsi-ctrl
+ - qcom,msm8996-dsi-ctrl
+ - qcom,qcm2290-dsi-ctrl
+ - qcom,sc7180-dsi-ctrl
+ - qcom,sc7280-dsi-ctrl
+ - qcom,sdm630-dsi-ctrl
+ - qcom,sdm660-dsi-ctrl
+ - qcom,sdm845-dsi-ctrl
+ - qcom,sm8250-dsi-ctrl
+ - const: qcom,mdss-dsi-ctrl

reg:
maxItems: 1
@@ -146,7 +157,7 @@ examples:
#include <dt-bindings/power/qcom-rpmpd.h>

dsi@ae94000 {
- compatible = "qcom,mdss-dsi-ctrl";
+ compatible = "qcom,sc7180-dsi-ctrl", "qcom,mdss-dsi-ctrl";
reg = <0x0ae94000 0x400>;
reg-names = "dsi_ctrl";

--
2.38.1

2022-11-26 18:59:52

by Dmitry Baryshkov

[permalink] [raw]
Subject: Re: [PATCH v4 03/18] dt-bindings: msm: dsi-controller-main: Rename qcom,dsi-ctrl-6g-qcm2290 to qcom,qcm2290-dsi-ctrl

On 25/11/2022 14:36, Bryan O'Donoghue wrote:
> We will add in a number of compat strings to dsi-controller-main.yaml in
> the format "qcom,socname-dsi-ctrl" convert the currently unused
> qcom,dsi-ctrl-6g-qcm2290 to qcom,qcm2290-dsi-ctrl.
>
> Signed-off-by: Bryan O'Donoghue <[email protected]>

I'd say, as you are going to introduce new bindings using two compat
strings, just leave this binding as is, marking it as deprecated.

> ---
> .../devicetree/bindings/display/msm/dsi-controller-main.yaml | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml b/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
> index cf782c5f5bdb0..67d08dc338925 100644
> --- a/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
> +++ b/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
> @@ -16,7 +16,7 @@ properties:
> compatible:
> enum:
> - qcom,mdss-dsi-ctrl
> - - qcom,dsi-ctrl-6g-qcm2290
> + - qcom,qcm2290-dsi-ctrl
>
> reg:
> maxItems: 1

--
With best wishes
Dmitry

2022-11-26 19:14:14

by Dmitry Baryshkov

[permalink] [raw]
Subject: Re: [PATCH v4 04/18] dt-bindings: msm: dsi-controller-main: Add compatible strings for every current SoC

On 25/11/2022 14:36, Bryan O'Donoghue wrote:
> Currently we do not differentiate between the various users of the
> qcom,mdss-dsi-ctrl. The driver is flexible enough to operate from one
> compatible string but, the hardware does have some significant differences
> in the number of clocks.
>
> To facilitate documenting the clocks add the following compatible strings
>
> - qcom,apq8064-dsi-ctrl
> - qcom,msm8916-dsi-ctrl
> - qcom,msm8974-dsi-ctrl
> - qcom,msm8996-dsi-ctrl
> - qcom,sc7180-dsi-ctrl
> - qcom,sc7280-dsi-ctrl
> - qcom,sdm630-dsi-ctrl
> - qcom,sdm660-dsi-ctrl
> - qcom,sdm845-dsi-ctrl
> - qcom,sm8250-dsi-ctrl
>
> Each SoC dtsi should declare "qcom,socname-dsi-ctrl", "qcom,mdss-dsi-ctrl";
>
> Signed-off-by: Bryan O'Donoghue <[email protected]>
> ---
> .../display/msm/dsi-controller-main.yaml | 19 +++++++++++++++----
> 1 file changed, 15 insertions(+), 4 deletions(-)
>
> diff --git a/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml b/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
> index 67d08dc338925..0cd2079137b02 100644
> --- a/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
> +++ b/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
> @@ -14,9 +14,20 @@ allOf:
>
> properties:
> compatible:
> - enum:
> - - qcom,mdss-dsi-ctrl
> - - qcom,qcm2290-dsi-ctrl
> + items:
> + - enum:
> + - qcom,apq8064-dsi-ctrl
> + - qcom,msm8916-dsi-ctrl
> + - qcom,msm8974-dsi-ctrl
> + - qcom,msm8996-dsi-ctrl
> + - qcom,qcm2290-dsi-ctrl
> + - qcom,sc7180-dsi-ctrl
> + - qcom,sc7280-dsi-ctrl
> + - qcom,sdm630-dsi-ctrl
> + - qcom,sdm660-dsi-ctrl
> + - qcom,sdm845-dsi-ctrl
> + - qcom,sm8250-dsi-ctrl
> + - const: qcom,mdss-dsi-ctrl
>
> reg:
> maxItems: 1
> @@ -146,7 +157,7 @@ examples:
> #include <dt-bindings/power/qcom-rpmpd.h>
>
> dsi@ae94000 {
> - compatible = "qcom,mdss-dsi-ctrl";
> + compatible = "qcom,sc7180-dsi-ctrl", "qcom,mdss-dsi-ctrl";

Other examples (from qcom,SOC-mdss.yaml) also must be updated.

> reg = <0x0ae94000 0x400>;
> reg-names = "dsi_ctrl";
>

--
With best wishes
Dmitry

2022-11-26 19:15:05

by Dmitry Baryshkov

[permalink] [raw]
Subject: Re: [PATCH v4 15/18] arm64: dts: qcom: sdm630: Add compat qcom,sdm630-dsi-ctrl

On 25/11/2022 14:36, Bryan O'Donoghue wrote:
> Add silicon specific compatible qcom,sdm630-dsi-ctrl to the
> mdss-dsi-ctrl block. This allows us to differentiate the specific bindings
> for sdm630 against the yaml documentation.
>
> Signed-off-by: Bryan O'Donoghue <[email protected]>
> ---
> arch/arm64/boot/dts/qcom/sdm630.dtsi | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)

Reviewed-by: Dmitry Baryshkov <[email protected]>

--
With best wishes
Dmitry

2022-11-26 19:15:05

by Dmitry Baryshkov

[permalink] [raw]
Subject: Re: [PATCH v4 06/18] dt-bindings: msm: dsi-controller-main: Fix description of core clock

On 25/11/2022 14:36, Bryan O'Donoghue wrote:
> There's a typo in describing the core clock as an 'escape' clock. The
> accurate description is 'core'.
>
> Fixes: 4dbe55c97741 ("dt-bindings: msm: dsi: add yaml schemas for DSI bindings")
> Reviewed-by: Dmitry Baryshkov <[email protected]>
> Acked-by: Krzysztof Kozlowski <[email protected]>
> Signed-off-by: Bryan O'Donoghue <[email protected]>

In the next spin please move this patch after first two fixes, so all
three of them can be picked into -fixes.

> ---
> .../devicetree/bindings/display/msm/dsi-controller-main.yaml | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml b/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
> index 88aac7d33555c..0c09b9230b7f5 100644
> --- a/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
> +++ b/Documentation/devicetree/bindings/display/msm/dsi-controller-main.yaml
> @@ -40,7 +40,7 @@ properties:
> - description: Display byte clock
> - description: Display byte interface clock
> - description: Display pixel clock
> - - description: Display escape clock
> + - description: Display core clock
> - description: Display AHB clock
> - description: Display AXI clock
>

--
With best wishes
Dmitry

2022-11-26 19:16:51

by Dmitry Baryshkov

[permalink] [raw]
Subject: Re: [PATCH v4 17/18] arm64: dts: qcom: sdm845: Add compat qcom,sdm845-dsi-ctrl

On 25/11/2022 14:36, Bryan O'Donoghue wrote:
> Add silicon specific compatible qcom,sdm845-dsi-ctrl to the
> mdss-dsi-ctrl block. This allows us to differentiate the specific bindings
> for sdm845 against the yaml documentation.
>
> Reviewed-by: Douglas Anderson <[email protected]>
> Signed-off-by: Bryan O'Donoghue <[email protected]>
> ---
> arch/arm64/boot/dts/qcom/sdm845.dtsi | 6 ++++--
> 1 file changed, 4 insertions(+), 2 deletions(-)

Reviewed-by: Dmitry Baryshkov <[email protected]>

--
With best wishes
Dmitry

2022-11-26 19:49:32

by Dmitry Baryshkov

[permalink] [raw]
Subject: Re: [PATCH v4 11/18] arm64: dts: qcom: msm8916: Add compat qcom,msm8916-dsi-ctrl

On 25/11/2022 14:36, Bryan O'Donoghue wrote:
> Add silicon specific compatible qcom,msm8916-dsi-ctrl to the
> mdss-dsi-ctrl block. This allows us to differentiate the specific bindings
> for msm8916 against the yaml documentation.
>
> Signed-off-by: Bryan O'Donoghue <[email protected]>
> ---
> arch/arm64/boot/dts/qcom/msm8916.dtsi | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)

Reviewed-by: Dmitry Baryshkov <[email protected]>

--
With best wishes
Dmitry

2022-11-26 20:36:48

by Dmitry Baryshkov

[permalink] [raw]
Subject: Re: [PATCH v4 18/18] arm64: dts: qcom: sm8250: Add compat qcom,sm8250-dsi-ctrl

On 25/11/2022 14:36, Bryan O'Donoghue wrote:
> Add silicon specific compatible qcom,sm8250-dsi-ctrl to the
> mdss-dsi-ctrl block. This allows us to differentiate the specific bindings
> for sm8250 against the yaml documentation.
>
> Signed-off-by: Bryan O'Donoghue <[email protected]>
> ---
> arch/arm64/boot/dts/qcom/sm8250.dtsi | 6 ++++--
> 1 file changed, 4 insertions(+), 2 deletions(-)

Reviewed-by: Dmitry Baryshkov <[email protected]>

--
With best wishes
Dmitry

2022-11-26 20:38:18

by Dmitry Baryshkov

[permalink] [raw]
Subject: Re: [PATCH v4 16/18] arm64: dts: qcom: sdm660: Add compat qcom,sdm660-dsi-ctrl

On 25/11/2022 14:36, Bryan O'Donoghue wrote:
> Add silicon specific compatible qcom,sdm660-dsi-ctrl to the
> mdss-dsi-ctrl block. This allows us to differentiate the specific bindings
> for sdm660 against the yaml documentation.
>
> Signed-off-by: Bryan O'Donoghue <[email protected]>
> ---
> arch/arm64/boot/dts/qcom/sdm660.dtsi | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/arch/arm64/boot/dts/qcom/sdm660.dtsi b/arch/arm64/boot/dts/qcom/sdm660.dtsi
> index 10bf1c45cf6ec..f8ec728e67f3d 100644
> --- a/arch/arm64/boot/dts/qcom/sdm660.dtsi
> +++ b/arch/arm64/boot/dts/qcom/sdm660.dtsi
> @@ -154,7 +154,8 @@ mdp5_intf2_out: endpoint {
>
> &mdss {
> dsi1: dsi@c996000 {
> - compatible = "qcom,mdss-dsi-ctrl";
> + compatible = "qcom,sdm660-dsi-ctrl",
> + "qcom,mdss-dsi-ctrl";

So, we'd end up with two identical DSI hosts, but one has compatible
'qcom,sdm660-dsi-ctrl' and another one 'qcom,sdm630-dsi-ctrl'.

I think, use sdm660 for both of them (for both sdm630 and sdm660)

> reg = <0x0c996000 0x400>;
> reg-names = "dsi_ctrl";
>

--
With best wishes
Dmitry

2022-11-27 12:34:54

by Bryan O'Donoghue

[permalink] [raw]
Subject: Re: [PATCH v4 02/18] dt-bindings: msm: dsi-controller-main: Fix power-domain constraint

On 25/11/2022 12:36, Bryan O'Donoghue wrote:
> power-domain is required for the sc7180 dispcc GDSC but not every qcom SoC
> has a similar dependency for example the aqp8064.

Note to self "apq8064"

2022-11-30 22:56:22

by Rob Herring (Arm)

[permalink] [raw]
Subject: Re: [PATCH v4 03/18] dt-bindings: msm: dsi-controller-main: Rename qcom,dsi-ctrl-6g-qcm2290 to qcom,qcm2290-dsi-ctrl

On Sat, Nov 26, 2022 at 08:54:11PM +0200, Dmitry Baryshkov wrote:
> On 25/11/2022 14:36, Bryan O'Donoghue wrote:
> > We will add in a number of compat strings to dsi-controller-main.yaml in
> > the format "qcom,socname-dsi-ctrl" convert the currently unused
> > qcom,dsi-ctrl-6g-qcm2290 to qcom,qcm2290-dsi-ctrl.
> >
> > Signed-off-by: Bryan O'Donoghue <[email protected]>
>
> I'd say, as you are going to introduce new bindings using two compat
> strings, just leave this binding as is, marking it as deprecated.

But if it was unused, then it's okay to just change it.

Rob

2022-12-05 20:17:01

by Rob Herring (Arm)

[permalink] [raw]
Subject: Re: [PATCH v4 07/18] dt-bindings: msm: dsi-controller-main: Fix clock declarations


On Fri, 25 Nov 2022 12:36:27 +0000, Bryan O'Donoghue wrote:
> When converting from .txt to .yaml dt-binding descriptions we appear to
> have missed some of the previous detail on the number and names of
> permissible clocks.
>
> Fix this by listing the clock descriptions against the clock names at a
> high level.
>
> Fixes: 4dbe55c97741 ("dt-bindings: msm: dsi: add yaml schemas for DSI bindings")
> Signed-off-by: Bryan O'Donoghue <[email protected]>
> ---
> .../display/msm/dsi-controller-main.yaml | 20 ++++++++++++-------
> 1 file changed, 13 insertions(+), 7 deletions(-)
>

Acked-by: Rob Herring <[email protected]>

2022-12-05 20:41:26

by Rob Herring (Arm)

[permalink] [raw]
Subject: Re: [PATCH v4 05/18] dt-bindings: msm: dsi-controller-main: Document clocks on a per compatible basis


On Fri, 25 Nov 2022 12:36:25 +0000, Bryan O'Donoghue wrote:
> Each compatible has a different set of clocks which are associated with it.
> Add in the list of clocks for each compatible.
>
> Signed-off-by: Bryan O'Donoghue <[email protected]>
> ---
> .../display/msm/dsi-controller-main.yaml | 152 ++++++++++++++++--
> 1 file changed, 142 insertions(+), 10 deletions(-)
>

Acked-by: Rob Herring <[email protected]>