[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <5e980bfe-c939-478b-833e-d5816c3ed77f@linaro.org>
Date: Mon, 10 Jun 2024 14:50:41 +0200
From: Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>
To: Adam Skladowski <a39.skl@...il.com>
Cc: phone-devel@...r.kernel.org, ~postmarketos/upstreaming@...ts.sr.ht,
Andy Gross <agross@...nel.org>, Bjorn Andersson <andersson@...nel.org>,
Konrad Dybcio <konrad.dybcio@...aro.org>, Georgi Djakov <djakov@...nel.org>,
Rob Herring <robh+dt@...nel.org>,
Krzysztof Kozlowski <krzysztof.kozlowski+dt@...aro.org>,
Conor Dooley <conor+dt@...nel.org>, linux-arm-msm@...r.kernel.org,
linux-pm@...r.kernel.org, devicetree@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH 1/7] dt-bindings: interconnect: Add Qualcomm MSM8976 DT
bindings
On 09/06/2024 20:20, Adam Skladowski wrote:
> Add bindings for Qualcomm MSM8976 Network-On-Chip interconnect devices.
>
> Signed-off-by: Adam Skladowski <a39.skl@...il.com>
A nit, subject: drop second/last, redundant "DT bindings". The
"dt-bindings" prefix is already stating that these are bindings.
See also:
https://elixir.bootlin.com/linux/v6.7-rc8/source/Documentation/devicetree/bindings/submitting-patches.rst#L18
> ---
> .../bindings/interconnect/qcom,msm8976.yaml | 107 ++++++++++++++++++
> .../dt-bindings/interconnect/qcom,msm8976.h | 97 ++++++++++++++++
> 2 files changed, 204 insertions(+)
> create mode 100644 Documentation/devicetree/bindings/interconnect/qcom,msm8976.yaml
> create mode 100644 include/dt-bindings/interconnect/qcom,msm8976.h
>
> diff --git a/Documentation/devicetree/bindings/interconnect/qcom,msm8976.yaml b/Documentation/devicetree/bindings/interconnect/qcom,msm8976.yaml
> new file mode 100644
> index 000000000000..bc9d08443e7c
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/interconnect/qcom,msm8976.yaml
> @@ -0,0 +1,107 @@
> +# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/interconnect/qcom,msm8976.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Qualcomm MSM8976 Network-On-Chip interconnect
> +
> +maintainers:
> + - Konrad Dybcio <konradybcio@...nel.org>
> +
> +description: |
Do not need '|' unless you need to preserve formatting.
> + The Qualcomm MSM8976 interconnect providers support adjusting the
> + bandwidth requirements between the various NoC fabrics.
> +
> +properties:
> + compatible:
> + enum:
> + - qcom,msm8976-bimc
> + - qcom,msm8976-pcnoc
> + - qcom,msm8976-snoc
> +
> + reg:
> + maxItems: 1
> +
> + clock-names:
> + minItems: 1
> + maxItems: 2
> +
> + clocks:
> + minItems: 1
> + maxItems: 2
I know that other qcom bindings use that order (clock-names -> clocks),
but at least for new bindings let's keep it more logical, so please
first clocks then clock-names.
> +
> +patternProperties:
> + '^interconnect-[a-z0-9\-]+$':
> + type: object
> + $ref: qcom,rpm-common.yaml#
> + description:
> + The interconnect providers do not have a separate QoS register space,
> + but share parent's space.
> +
> + allOf:
> + - $ref: qcom,rpm-common.yaml#
Drop both lines.
> +
> + properties:
> + compatible:
> + const: qcom,msm8976-snoc-mm
> +
> + required:
> + - compatible
> +
> + unevaluatedProperties: false
Put it after $ref (before description).
> +
> +required:
> + - compatible
> + - reg
> +
> +unevaluatedProperties: false
This goes after entire allOf section
> +
> +allOf:
> + - $ref: qcom,rpm-common.yaml#
> + - if:
> + properties:
> + compatible:
> + const: qcom,msm8976-snoc
> +
> + then:
> + properties:
> + clocks:
> + items:
> + - description: IPA clock from RPMCC
> + clock-names:
> + const: ipa
> +
> + required:
> + - clocks
> + - clock-names
Then why do you have two items? And what with clocks for other variants?
This is supposed to be fixed/specific for each device/variant.
> +
> +examples:
> + - |
> + #include <dt-bindings/clock/qcom,rpmcc.h>
> + #include <dt-bindings/interconnect/qcom,rpm-icc.h>
> +
> + bimc: interconnect@...000 {
> + compatible = "qcom,msm8976-bimc";
> + reg = <0x00400000 0x62000>;
> + #interconnect-cells = <2>;
> + };
> +
> + pcnoc: interconnect@...000 {
> + compatible = "qcom,msm8976-pcnoc";
> + reg = <0x00500000 0x14000>;
> + #interconnect-cells = <2>;
> + };
Drop both nodes. The node below is enough as an example.
Best regards,
Krzysztof
Powered by blists - more mailing lists