[1/7] dt-bindings: interconnect: qcom: Introduce qcom,rpm-common
Commit Message
The current RPM interconnect bindings are messy. Start cleaning them
up with a common include.
Signed-off-by: Konrad Dybcio <konrad.dybcio@linaro.org>
---
.../bindings/interconnect/qcom,qcm2290.yaml | 12 +++------
.../bindings/interconnect/qcom,rpm-common.yaml | 31 ++++++++++++++++++++++
2 files changed, 35 insertions(+), 8 deletions(-)
Comments
On 21/07/2023 15:54, Konrad Dybcio wrote:
> The current RPM interconnect bindings are messy. Start cleaning them
> up with a common include.
>
> Signed-off-by: Konrad Dybcio <konrad.dybcio@linaro.org>
> ---
> .../bindings/interconnect/qcom,qcm2290.yaml | 12 +++------
> .../bindings/interconnect/qcom,rpm-common.yaml | 31 ++++++++++++++++++++++
> 2 files changed, 35 insertions(+), 8 deletions(-)
>
> diff --git a/Documentation/devicetree/bindings/interconnect/qcom,qcm2290.yaml b/Documentation/devicetree/bindings/interconnect/qcom,qcm2290.yaml
> index f65a2fe846de..edee78c456b7 100644
> --- a/Documentation/devicetree/bindings/interconnect/qcom,qcm2290.yaml
> +++ b/Documentation/devicetree/bindings/interconnect/qcom,qcm2290.yaml
> @@ -13,19 +13,16 @@ description: |
> The Qualcomm QCM2290 interconnect providers support adjusting the
> bandwidth requirements between the various NoC fabrics.
>
> -properties:
> - reg:
> - maxItems: 1
> +allOf:
> + - $ref: qcom,rpm-common.yaml#
>
> +properties:
> compatible:
> enum:
> - qcom,qcm2290-bimc
> - qcom,qcm2290-cnoc
> - qcom,qcm2290-snoc
>
> - '#interconnect-cells':
> - const: 1
> -
> clock-names:
> items:
> - const: bus
What about the children? Aren't they also rpm-common?
> @@ -75,11 +72,10 @@ patternProperties:
> required:
> - compatible
> - reg
> - - '#interconnect-cells'
> - clock-names
> - clocks
>
> -additionalProperties: false
> +unevaluatedProperties: false
>
> examples:
> - |
> diff --git a/Documentation/devicetree/bindings/interconnect/qcom,rpm-common.yaml b/Documentation/devicetree/bindings/interconnect/qcom,rpm-common.yaml
> new file mode 100644
> index 000000000000..87995b40a856
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/interconnect/qcom,rpm-common.yaml
> @@ -0,0 +1,31 @@
> +# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/interconnect/qcom,rpm-common.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Qualcomm RPMh Network-On-Chip Interconnect
> +
> +maintainers:
> + - Konrad Dybcio <konradybcio@kernel.org>
> +
> +description:
> + RPM interconnect providers support for managing system bandwidth requirements
> + through manual requests based on either predefined values or as indicated by
> + the bus monitor hardware. Each provider node represents a NoC bus master,
> + driven by a dedicated clock source.
> +
> +properties:
> + reg:
> + maxItems: 1
I would drop the reg from common parts because some of the children here
don't use it.
Best regards,
Krzysztof
@@ -13,19 +13,16 @@ description: |
The Qualcomm QCM2290 interconnect providers support adjusting the
bandwidth requirements between the various NoC fabrics.
-properties:
- reg:
- maxItems: 1
+allOf:
+ - $ref: qcom,rpm-common.yaml#
+properties:
compatible:
enum:
- qcom,qcm2290-bimc
- qcom,qcm2290-cnoc
- qcom,qcm2290-snoc
- '#interconnect-cells':
- const: 1
-
clock-names:
items:
- const: bus
@@ -75,11 +72,10 @@ patternProperties:
required:
- compatible
- reg
- - '#interconnect-cells'
- clock-names
- clocks
-additionalProperties: false
+unevaluatedProperties: false
examples:
- |
new file mode 100644
@@ -0,0 +1,31 @@
+# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
+%YAML 1.2
+---
+$id: http://devicetree.org/schemas/interconnect/qcom,rpm-common.yaml#
+$schema: http://devicetree.org/meta-schemas/core.yaml#
+
+title: Qualcomm RPMh Network-On-Chip Interconnect
+
+maintainers:
+ - Konrad Dybcio <konradybcio@kernel.org>
+
+description:
+ RPM interconnect providers support for managing system bandwidth requirements
+ through manual requests based on either predefined values or as indicated by
+ the bus monitor hardware. Each provider node represents a NoC bus master,
+ driven by a dedicated clock source.
+
+properties:
+ reg:
+ maxItems: 1
+
+ '#interconnect-cells':
+ oneOf:
+ - const: 2
+ - const: 1
+ deprecated: true
+
+required:
+ - '#interconnect-cells'
+
+additionalProperties: true