Skip to contentSkip to conversation

Krait Documentation conversion

PATCH Superseded Ansuel Smith 4 participants 10 messages Apr 29, 2022

Subsystems (4)

v1 of 7 Superseded Latest is v7 →

lore
Share & tools
lore
#0 lore raw

cover Krait Documentation conversion

This series convert the krait-cc and the kpps-acc/gcc Documentation to yaml.

This series comes form a split of a bigger series that got too big and now hard to review.

While they are still more or less wrong and doesn't really reflect real driver implementation, they are converted to prepare for a fixup later when dts and driver are finally fixed. For now make a 1:1 conversion.

Ansuel Smith (3):
dt-bindings: clock: Convert qcom,krait-cc to yaml
dt-bindings: arm: msm: Convert kpss-acc driver Documentation to yaml
dt-bindings: arm: msm: Convert kpss-gcc driver Documentation to yaml

 .../bindings/arm/msm/qcom,kpss-acc.txt        | 49 ----------
 .../bindings/arm/msm/qcom,kpss-acc.yaml       | 94 +++++++++++++++++++
 .../bindings/arm/msm/qcom,kpss-gcc.txt        | 44 ---------
 .../bindings/arm/msm/qcom,kpss-gcc.yaml       | 63 +++++++++++++
 .../bindings/clock/qcom,krait-cc.txt          | 34 -------
 .../bindings/clock/qcom,krait-cc.yaml         | 59 ++++++++++++
 6 files changed, 216 insertions(+), 127 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/arm/msm/qcom,kpss-acc.txt
 create mode 100644 Documentation/devicetree/bindings/arm/msm/qcom,kpss-acc.yaml
 delete mode 100644 Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.txt
 create mode 100644 Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.yaml
 delete mode 100644 Documentation/devicetree/bindings/clock/qcom,krait-cc.txt
 create mode 100644 Documentation/devicetree/bindings/clock/qcom,krait-cc.yaml
Signature · 1 line
2.34.1
#1 lore raw

PATCH 1/3 dt-bindings: clock: Convert qcom,krait-cc to yaml

Convert qcom,krait-cc to yaml Documentation.

---
 .../bindings/clock/qcom,krait-cc.txt          | 34 -----------
 .../bindings/clock/qcom,krait-cc.yaml         | 59 +++++++++++++++++++
 2 files changed, 59 insertions(+), 34 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/clock/qcom,krait-cc.txt
 create mode 100644 Documentation/devicetree/bindings/clock/qcom,krait-cc.yaml
Documentation/devicetree/bindings/clock/qcom,krait-cc.txt deleted +0 -34
deleted file mode 100644
index 030ba60dab08..000000000000
@@ -1,34 +0,0 @@
-Krait Clock Controller
-
-PROPERTIES
-
-- compatible:
-	Usage: required
-	Value type: <string>
-	Definition: must be one of:
-			"qcom,krait-cc-v1"
-			"qcom,krait-cc-v2"
-
-- #clock-cells:
-	Usage: required
-	Value type: <u32>
-	Definition: must be 1
-
-- clocks:
-	Usage: required
-	Value type: <prop-encoded-array>
-	Definition: reference to the clock parents of hfpll, secondary muxes.
-
-- clock-names:
-	Usage: required
-	Value type: <stringlist>
-	Definition: must be "hfpll0", "hfpll1", "acpu0_aux", "acpu1_aux", "qsb".
-
-Example:
-
-	kraitcc: clock-controller {
-		compatible = "qcom,krait-cc-v1";
-		clocks = <&hfpll0>, <&hfpll1>, <&acpu0_aux>, <&acpu1_aux>, <qsb>;
-		clock-names = "hfpll0", "hfpll1", "acpu0_aux", "acpu1_aux", "qsb";
-		#clock-cells = <1>;
-	};
Documentation/devicetree/bindings/clock/qcom,krait-cc.yaml new file +59 -0

59 lines not on this page · raw message

Signature · 1 line
2.34.1
#2 lore raw

PATCH 2/3 dt-bindings: arm: msm: Convert kpss-acc driver Documentation to yaml

In reply to Ansuel Smith

Convert kpss-acc driver Documentation to yaml.
The original Documentation was wrong all along. Fix it while we are converting it.
The example was wrong as kpss-acc-v2 should only expose the regs but we don't have any driver that expose additional clocks. The kpss-acc driver is only specific to v1. For this exact reason, limit all the additional bindings (clocks, clock-names, clock-output-names and #clock-cells) to v1 and also flag that these bindings should NOT be used for v2.

---
 .../bindings/arm/msm/qcom,kpss-acc.txt        | 49 ----------
 .../bindings/arm/msm/qcom,kpss-acc.yaml       | 94 +++++++++++++++++++
 2 files changed, 94 insertions(+), 49 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/arm/msm/qcom,kpss-acc.txt
 create mode 100644 Documentation/devicetree/bindings/arm/msm/qcom,kpss-acc.yaml
Documentation/devicetree/bindings/arm/msm/qcom,kpss-acc.txt deleted +0 -49
deleted file mode 100644
index 7f696362a4a1..000000000000
@@ -1,49 +0,0 @@
-Krait Processor Sub-system (KPSS) Application Clock Controller (ACC)
-
-The KPSS ACC provides clock, power domain, and reset control to a Krait CPU.
-There is one ACC register region per CPU within the KPSS remapped region as
-well as an alias register region that remaps accesses to the ACC associated
-with the CPU accessing the region.
-
-PROPERTIES
-
-- compatible:
-	Usage: required
-	Value type: <string>
-	Definition: should be one of:
-			"qcom,kpss-acc-v1"
-			"qcom,kpss-acc-v2"
-
-- reg:
-	Usage: required
-	Value type: <prop-encoded-array>
-	Definition: the first element specifies the base address and size of
-		    the register region. An optional second element specifies
-		    the base address and size of the alias register region.
-
-- clocks:
-        Usage: required
-        Value type: <prop-encoded-array>
-        Definition: reference to the pll parents.
-
-- clock-names:
-        Usage: required
-        Value type: <stringlist>
-        Definition: must be "pll8_vote", "pxo".
-
-- clock-output-names:
-	Usage: optional
-	Value type: <string>
-	Definition: Name of the output clock. Typically acpuX_aux where X is a
-		    CPU number starting at 0.
-
-Example:
-
-	clock-controller@2088000 {
-		compatible = "qcom,kpss-acc-v2";
-		reg = <0x02088000 0x1000>,
-		      <0x02008000 0x1000>;
-		clocks = <&gcc PLL8_VOTE>, <&gcc PXO_SRC>;
-		clock-names = "pll8_vote", "pxo";
-		clock-output-names = "acpu0_aux";
-	};
Documentation/devicetree/bindings/arm/msm/qcom,kpss-acc.yaml new file +94 -0

94 lines not on this page · raw message

Signature · 1 line
2.34.1
#3 lore raw

PATCH 3/3 dt-bindings: arm: msm: Convert kpss-gcc driver Documentation to yaml

In reply to Ansuel Smith

Convert kpss-gcc driver Documentation to yaml.

---
 .../bindings/arm/msm/qcom,kpss-gcc.txt        | 44 -------------
 .../bindings/arm/msm/qcom,kpss-gcc.yaml       | 63 +++++++++++++++++++
 2 files changed, 63 insertions(+), 44 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.txt
 create mode 100644 Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.yaml
Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.txt deleted +0 -44
deleted file mode 100644
index e628758950e1..000000000000
@@ -1,44 +0,0 @@
-Krait Processor Sub-system (KPSS) Global Clock Controller (GCC)
-
-PROPERTIES
-
-- compatible:
-	Usage: required
-	Value type: <string>
-	Definition: should be one of the following. The generic compatible
-			"qcom,kpss-gcc" should also be included.
-			"qcom,kpss-gcc-ipq8064", "qcom,kpss-gcc"
-			"qcom,kpss-gcc-apq8064", "qcom,kpss-gcc"
-			"qcom,kpss-gcc-msm8974", "qcom,kpss-gcc"
-			"qcom,kpss-gcc-msm8960", "qcom,kpss-gcc"
-
-- reg:
-	Usage: required
-	Value type: <prop-encoded-array>
-	Definition: base address and size of the register region
-
-- clocks:
-	Usage: required
-	Value type: <prop-encoded-array>
-	Definition: reference to the pll parents.
-
-- clock-names:
-	Usage: required
-	Value type: <stringlist>
-	Definition: must be "pll8_vote", "pxo".
-
-- clock-output-names:
-	Usage: required
-	Value type: <string>
-	Definition: Name of the output clock. Typically acpu_l2_aux indicating
-		    an L2 cache auxiliary clock.
-
-Example:
-
-	l2cc: clock-controller@2011000 {
-		compatible = "qcom,kpss-gcc-ipq8064", "qcom,kpss-gcc";
-		reg = <0x2011000 0x1000>;
-		clocks = <&gcc PLL8_VOTE>, <&gcc PXO_SRC>;
-		clock-names = "pll8_vote", "pxo";
-		clock-output-names = "acpu_l2_aux";
-	};
Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.yaml new file +63 -0

63 lines not on this page · raw message

Signature · 1 line
2.34.1
maintainer
#4 lore raw

Re: [PATCH 3/3] dt-bindings: arm: msm: Convert kpss-gcc driver Documentation to yaml

Quoted 10 lines · Ansuel Smith

Convert kpss-gcc driver Documentation to yaml.

---
 .../bindings/arm/msm/qcom,kpss-gcc.txt        | 44 -------------
 .../bindings/arm/msm/qcom,kpss-gcc.yaml       | 63 +++++++++++++++++++
 2 files changed, 63 insertions(+), 44 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.txt
 create mode 100644 Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.yaml

My bot found errors running 'make DT_CHECKER_FLAGS=-m dt_binding_check' on your patch (DT_CHECKER_FLAGS is new in v5.13):

yamllint warnings/errors:

dtschema/dtc warnings/errors:
/builds/robherring/linux-dt-review/Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.yaml: properties: '#clock-cells' is a dependency of 'clock-output-names'
from schema $id: http://devicetree.org/meta-schemas/clocks.yaml#
/builds/robherring/linux-dt-review/Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.yaml: ignoring, error in schema: properties /builds/robherring/linux-dt-review/Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.example.dtb: clock-controller@2011000: '#clock-cells' is a dependency of 'clock-output-names'
From schema: /usr/local/lib/python3.10/dist-packages/dtschema/schemas/clock/clock.yaml
Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.example.dtb:0:0: /example-0/clock-controller@2011000: failed to match any schema with compatible: ['qcom,kpss-gcc-ipq8064', 'qcom,kpss-gcc'] Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.example.dtb:0:0: /example-0/clock-controller@2011000: failed to match any schema with compatible: ['qcom,kpss-gcc-ipq8064', 'qcom,kpss-gcc']

doc reference errors (make refcheckdocs):

See https://patchwork.ozlabs.org/patch/

This check can fail if there are any dependencies. The base for a patch series is generally the most recent rc1.

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.

#5 lore raw

Re: [PATCH 3/3] dt-bindings: arm: msm: Convert kpss-gcc driver Documentation to yaml

Quoted 12 lines · Rob Herring
Quoted 10 lines · Ansuel Smith

Convert kpss-gcc driver Documentation to yaml.

---
 .../bindings/arm/msm/qcom,kpss-gcc.txt        | 44 -------------
 .../bindings/arm/msm/qcom,kpss-gcc.yaml       | 63 +++++++++++++++++++
 2 files changed, 63 insertions(+), 44 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.txt
 create mode 100644 Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.yaml
Quoted 7 lines

My bot found errors running 'make DT_CHECKER_FLAGS=-m dt_binding_check' on your patch (DT_CHECKER_FLAGS is new in v5.13):

yamllint warnings/errors:

dtschema/dtc warnings/errors:
/builds/robherring/linux-dt-review/Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.yaml: properties: '#clock-cells' is a dependency of 'clock-output-names'

Erm how to fix this? I can't do a 1:1 conversion if the source was wrong and also have no bot warning.
Or I should just push an additional patch to fix this error after the conversion?

Quoted 22 lines

from schema $id: http://devicetree.org/meta-schemas/clocks.yaml#
/builds/robherring/linux-dt-review/Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.yaml: ignoring, error in schema: properties /builds/robherring/linux-dt-review/Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.example.dtb: clock-controller@2011000: '#clock-cells' is a dependency of 'clock-output-names'
From schema: /usr/local/lib/python3.10/dist-packages/dtschema/schemas/clock/clock.yaml
Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.example.dtb:0:0: /example-0/clock-controller@2011000: failed to match any schema with compatible: ['qcom,kpss-gcc-ipq8064', 'qcom,kpss-gcc'] Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.example.dtb:0:0: /example-0/clock-controller@2011000: failed to match any schema with compatible: ['qcom,kpss-gcc-ipq8064', 'qcom,kpss-gcc']

doc reference errors (make refcheckdocs):

See https://patchwork.ozlabs.org/patch/

This check can fail if there are any dependencies. The base for a patch series is generally the most recent rc1.

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.

Signature · 1 line
	Ansuel
#6 lore raw

Re: [PATCH 3/3] dt-bindings: arm: msm: Convert kpss-gcc driver Documentation to yaml

Quoted 19 lines · Ansuel Smith
Quoted 17 lines · Rob Herring
Quoted 10 lines · Ansuel Smith

Convert kpss-gcc driver Documentation to yaml.

---
 .../bindings/arm/msm/qcom,kpss-gcc.txt        | 44 -------------
 .../bindings/arm/msm/qcom,kpss-gcc.yaml       | 63 +++++++++++++++++++
 2 files changed, 63 insertions(+), 44 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.txt
 create mode 100644 Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.yaml

My bot found errors running 'make DT_CHECKER_FLAGS=-m dt_binding_check' on your patch (DT_CHECKER_FLAGS is new in v5.13):

yamllint warnings/errors:

Quoted 7 lines
Quoted 2 lines

dtschema/dtc warnings/errors:
/builds/robherring/linux-dt-review/Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.yaml: properties: '#clock-cells' is a dependency of 'clock-output-names'

Erm how to fix this? I can't do a 1:1 conversion if the source was wrong and also have no bot warning.
Or I should just push an additional patch to fix this error after the conversion?

You can fix obvious simple mistakes and describe your chains in the commit message.

Quoted 26 lines
Quoted 15 lines

from schema $id: http://devicetree.org/meta-schemas/clocks.yaml#
/builds/robherring/linux-dt-review/Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.yaml: ignoring, error in schema: properties /builds/robherring/linux-dt-review/Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.example.dtb: clock-controller@2011000: '#clock-cells' is a dependency of 'clock-output-names'
From schema: /usr/local/lib/python3.10/dist-packages/dtschema/schemas/clock/clock.yaml
Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.example.dtb:0:0: /example-0/clock-controller@2011000: failed to match any schema with compatible: ['qcom,kpss-gcc-ipq8064', 'qcom,kpss-gcc'] Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.example.dtb:0:0: /example-0/clock-controller@2011000: failed to match any schema with compatible: ['qcom,kpss-gcc-ipq8064', 'qcom,kpss-gcc']

doc reference errors (make refcheckdocs):

See https://patchwork.ozlabs.org/patch/

This check can fail if there are any dependencies. The base for a patch series is generally the most recent rc1.

Quoted 8 lines

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.

--
Ansuel

Signature · 2 lines
With best wishes
Dmitry
#7 lore raw

Re: [PATCH 3/3] dt-bindings: arm: msm: Convert kpss-gcc driver Documentation to yaml

In reply to Ansuel Smith
Quoted 13 lines · Ansuel Smith
Quoted 12 lines · Rob Herring
Quoted 10 lines · Ansuel Smith

Convert kpss-gcc driver Documentation to yaml.

---
 .../bindings/arm/msm/qcom,kpss-gcc.txt        | 44 -------------
 .../bindings/arm/msm/qcom,kpss-gcc.yaml       | 63 +++++++++++++++++++
 2 files changed, 63 insertions(+), 44 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.txt
 create mode 100644 Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.yaml
Quoted 8 lines
Quoted 7 lines

My bot found errors running 'make DT_CHECKER_FLAGS=-m dt_binding_check' on your patch (DT_CHECKER_FLAGS is new in v5.13):

yamllint warnings/errors:

dtschema/dtc warnings/errors:
/builds/robherring/linux-dt-review/Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.yaml: properties: '#clock-cells' is a dependency of 'clock-output-names'

The patches were previously sent (even as v6) and somehow the history, changelog and references disappeared...

Quoted 4 lines

Erm how to fix this? I can't do a 1:1 conversion if the source was wrong and also have no bot warning.
Or I should just push an additional patch to fix this error after the conversion?

Didn't we agree that original bindings were not in good shape? Yet the questions raised with your v6 remain actually not answered, till the bot complains.

Please do not send the bindings which do not pass dt_binding_check.

Best regards,
Krzysztof

#8 lore raw

Re: [PATCH 3/3] dt-bindings: arm: msm: Convert kpss-gcc driver Documentation to yaml

Quoted 17 lines · Krzysztof Kozlowski
Quoted 16 lines · Ansuel Smith
Quoted 15 lines · Rob Herring
Quoted 10 lines · Ansuel Smith

Convert kpss-gcc driver Documentation to yaml.

---
 .../bindings/arm/msm/qcom,kpss-gcc.txt        | 44 -------------
 .../bindings/arm/msm/qcom,kpss-gcc.yaml       | 63 +++++++++++++++++++
 2 files changed, 63 insertions(+), 44 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.txt
 create mode 100644 Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.yaml

My bot found errors running 'make DT_CHECKER_FLAGS=-m dt_binding_check' on your patch (DT_CHECKER_FLAGS is new in v5.13):

Quoted 9 lines
Quoted 5 lines
Quoted 4 lines

yamllint warnings/errors:

dtschema/dtc warnings/errors:
/builds/robherring/linux-dt-review/Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.yaml: properties: '#clock-cells' is a dependency of 'clock-output-names'

The patches were previously sent (even as v6) and somehow the history, changelog and references disappeared...

Mhh with split how this should be handled? Putting the relevant changes in the cover letter?

Quoted 5 lines
Quoted 4 lines

Erm how to fix this? I can't do a 1:1 conversion if the source was wrong and also have no bot warning.
Or I should just push an additional patch to fix this error after the conversion?

Quoted 8 lines

Didn't we agree that original bindings were not in good shape? Yet the questions raised with your v6 remain actually not answered, till the bot complains.

Please do not send the bindings which do not pass dt_binding_check.

Best regards,
Krzysztof

In v6 the last mail were with the idea of sending separate series with minimal changes and it was mention that it was a good idea to send only conversion and then send the changes with the conversion series.

Finally got the message. I should NEVER send patch with warning from dt_binding_check.

Signature · 1 line
	Ansuel
maintainer
#9 lore raw

Re: [PATCH 3/3] dt-bindings: arm: msm: Convert kpss-gcc driver Documentation to yaml

Quoted 45 lines · Ansuel Smith
Quoted 17 lines · Krzysztof Kozlowski
Quoted 16 lines · Ansuel Smith
Quoted 15 lines · Rob Herring
Quoted 10 lines · Ansuel Smith

Convert kpss-gcc driver Documentation to yaml.

---
 .../bindings/arm/msm/qcom,kpss-gcc.txt        | 44 -------------
 .../bindings/arm/msm/qcom,kpss-gcc.yaml       | 63 +++++++++++++++++++
 2 files changed, 63 insertions(+), 44 deletions(-)
 delete mode 100644 Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.txt
 create mode 100644 Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.yaml

My bot found errors running 'make DT_CHECKER_FLAGS=-m dt_binding_check' on your patch (DT_CHECKER_FLAGS is new in v5.13):

Quoted 9 lines
Quoted 5 lines
Quoted 4 lines

yamllint warnings/errors:

dtschema/dtc warnings/errors:
/builds/robherring/linux-dt-review/Documentation/devicetree/bindings/arm/msm/qcom,kpss-gcc.yaml: properties: '#clock-cells' is a dependency of 'clock-output-names'

The patches were previously sent (even as v6) and somehow the history, changelog and references disappeared...

Mhh with split how this should be handled? Putting the relevant changes in the cover letter?

Quoted 5 lines
Quoted 4 lines

Erm how to fix this? I can't do a 1:1 conversion if the source was wrong and also have no bot warning.
Or I should just push an additional patch to fix this error after the conversion?

Quoted 8 lines

Didn't we agree that original bindings were not in good shape? Yet the questions raised with your v6 remain actually not answered, till the bot complains.

Please do not send the bindings which do not pass dt_binding_check.

Best regards,
Krzysztof

Quoted 6 lines

In v6 the last mail were with the idea of sending separate series with minimal changes and it was mention that it was a good idea to send only conversion and then send the changes with the conversion series.

Finally got the message. I should NEVER send patch with warning from dt_binding_check.

It's like sending code changes that don't compile...

But I wouldn't say NEVER. If you have a warning that you think is wrong or don't know how to fix, then send it and say that in the patch.

Rob