mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
To: Konrad Dybcio <konrad.dybcio@linaro.org>,
	Andy Gross <agross@kernel.org>,
	Bjorn Andersson <andersson@kernel.org>,
	Joerg Roedel <joro@8bytes.org>, Will Deacon <will@kernel.org>,
	Robin Murphy <robin.murphy@arm.com>,
	Rob Herring <robh+dt@kernel.org>,
	Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>
Cc: Marijn Suijten <marijn.suijten@somainline.org>,
	linux-arm-msm@vger.kernel.org, iommu@lists.linux.dev,
	devicetree@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2] dt-bindings: iommu: Convert QCOM IOMMU to YAML
Date: Thu, 6 Apr 2023 20:07:44 +0200	[thread overview]
Message-ID: <cc5ee0e5-5cc7-bf80-68cc-2d38b1118c6d@linaro.org> (raw)
In-Reply-To: <20230406-topic-qciommu-v2-1-b8547622b2a4@linaro.org>

On 06/04/2023 13:58, Konrad Dybcio wrote:
> Convert the Qualcomm IOMMU bindings to YAML.
> 
> Signed-off-by: Konrad Dybcio <konrad.dybcio@linaro.org>
> ---
> v1 -> v2:

Thank you for your patch. There is something to discuss/improve.

> +
> +patternProperties:
> +  "^iommu-ctx@[0-9a-f]+$":
> +    type: object

On this level:
additionalProperties: false

> +    properties:
> +      compatible:
> +        enum:
> +          - qcom,msm-iommu-v1-ns
> +          - qcom,msm-iommu-v1-sec
> +
> +      interrupts:
> +        maxItems: 1
> +
> +      reg:
> +        maxItems: 1

On this level:
    required:
      - compatible
      - interrupts
      - reg

> +
> +required:
> +  - compatible
> +  - clocks
> +  - clock-names
> +  - ranges
> +  - '#address-cells'
> +  - '#size-cells'
> +  - '#iommu-cells'
> +
> +additionalProperties: false
> +
> +examples:
> +  - |
> +    #include <dt-bindings/clock/qcom,gcc-msm8916.h>
> +    #include <dt-bindings/interrupt-controller/arm-gic.h>
> +
> +    apps_iommu: iommu@1e20000 {
> +      compatible = "qcom,msm8916-iommu", "qcom,msm-iommu-v1";
> +      reg = <0x01ef0000 0x3000>;
> +      clocks = <&gcc GCC_SMMU_CFG_CLK>,
> +               <&gcc GCC_APSS_TCU_CLK>;
> +      clock-names = "iface", "bus";
> +      qcom,iommu-secure-id = <17>;
> +      #address-cells = <1>;
> +      #size-cells = <1>;
> +      #iommu-cells = <1>;
> +      ranges = <0 0x01e20000 0x40000>;
> +
> +      /* mdp_0: */
> +      iommu-ctx@4000 {
> +        compatible = "qcom,msm-iommu-v1-ns";
> +        reg = <0x4000 0x1000>;
> +        interrupts = <GIC_SPI 70 IRQ_TYPE_LEVEL_HIGH>;
> +      };
> +    };
> +
> +    mdp: mdp@1a01000 {
> +      reg = <0x01a01000 0x1000>;
> +      iommus = <&apps_iommu 4>;

Drop mdp node. Consumers should not be in provider bindings.



Best regards,
Krzysztof


      reply	other threads:[~2023-04-06 18:07 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-04-06 11:58 Konrad Dybcio
2023-04-06 18:07 ` Krzysztof Kozlowski [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=cc5ee0e5-5cc7-bf80-68cc-2d38b1118c6d@linaro.org \
    --to=krzysztof.kozlowski@linaro.org \
    --cc=agross@kernel.org \
    --cc=andersson@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=iommu@lists.linux.dev \
    --cc=joro@8bytes.org \
    --cc=konrad.dybcio@linaro.org \
    --cc=krzysztof.kozlowski+dt@linaro.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=marijn.suijten@somainline.org \
    --cc=robh+dt@kernel.org \
    --cc=robin.murphy@arm.com \
    --cc=will@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®