devicetree.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Rob Herring <robh@kernel.org>
To: cyndis@kapsi.fi
Cc: thierry.reding@gmail.com, jonathanh@nvidia.com,
	krzysztof.kozlowski+dt@linaro.org, digetx@gmail.com,
	dri-devel@lists.freedesktop.org, devicetree@vger.kernel.org,
	linux-tegra@vger.kernel.org, linux-kernel@vger.kernel.org,
	Mikko Perttunen <mperttunen@nvidia.com>
Subject: Re: [PATCH v1 01/13] dt-bindings: Add bindings for Tegra234 Host1x and VIC
Date: Mon, 16 May 2022 11:33:25 -0500	[thread overview]
Message-ID: <20220516163325.GA2793304-robh@kernel.org> (raw)
In-Reply-To: <20220516100213.1536571-2-cyndis@kapsi.fi>

On Mon, May 16, 2022 at 01:02:01PM +0300, cyndis@kapsi.fi wrote:
> From: Mikko Perttunen <mperttunen@nvidia.com>
> 
> Update VIC and Host1x bindings for changes in Tegra234.
> 
> Namely,
> - New compatible strings
> - Sharded syncpoint interrupts
> - Optional reset.
> 
> Signed-off-by: Mikko Perttunen <mperttunen@nvidia.com>
> ---
>  .../display/tegra/nvidia,tegra124-vic.yaml    |   1 +
>  .../display/tegra/nvidia,tegra20-host1x.yaml  | 108 +++++++++++++++---
>  2 files changed, 95 insertions(+), 14 deletions(-)
> 
> diff --git a/Documentation/devicetree/bindings/display/tegra/nvidia,tegra124-vic.yaml b/Documentation/devicetree/bindings/display/tegra/nvidia,tegra124-vic.yaml
> index 37bb5ddc1963..7200095ef19e 100644
> --- a/Documentation/devicetree/bindings/display/tegra/nvidia,tegra124-vic.yaml
> +++ b/Documentation/devicetree/bindings/display/tegra/nvidia,tegra124-vic.yaml
> @@ -21,6 +21,7 @@ properties:
>            - nvidia,tegra210-vic
>            - nvidia,tegra186-vic
>            - nvidia,tegra194-vic
> +          - nvidia,tegra234-vic
>  
>        - items:
>            - const: nvidia,tegra132-vic
> diff --git a/Documentation/devicetree/bindings/display/tegra/nvidia,tegra20-host1x.yaml b/Documentation/devicetree/bindings/display/tegra/nvidia,tegra20-host1x.yaml
> index 0adeb03b9e3a..83c58b7dae98 100644
> --- a/Documentation/devicetree/bindings/display/tegra/nvidia,tegra20-host1x.yaml
> +++ b/Documentation/devicetree/bindings/display/tegra/nvidia,tegra20-host1x.yaml
> @@ -24,6 +24,7 @@ properties:
>            - nvidia,tegra210-host1x
>            - nvidia,tegra186-host1x
>            - nvidia,tegra194-host1x
> +          - nvidia,tegra234-host1x
>  
>        - items:
>            - const: nvidia,tegra132-host1x
> @@ -31,23 +32,19 @@ properties:
>  
>    reg:
>      minItems: 1
> -    maxItems: 2
> +    maxItems: 3
>  
>    reg-names:
>      minItems: 1
> -    maxItems: 2
> +    maxItems: 3
>  
>    interrupts:
> -    items:
> -      - description: host1x syncpoint interrupt
> -      - description: host1x general interrupt
>      minItems: 1
> +    maxItems: 9
>  
>    interrupt-names:
> -    items:
> -      - const: syncpt
> -      - const: host1x
>      minItems: 1
> +    maxItems: 9
>  
>    '#address-cells':
>      description: The number of cells used to represent physical base addresses
> @@ -110,13 +107,32 @@ required:
>    - reg
>    - clocks
>    - clock-names
> -  - resets
> -  - reset-names

Shouldn't these still be required on some platforms?

>  
>  additionalProperties:
>    type: object
>  
>  allOf:
> +  - if:
> +      properties:
> +        compatible:
> +          contains:
> +            enum:
> +              - nvidia,tegra20-host1x
> +              - nvidia,tegra30-host1x
> +              - nvidia,tegra114-host1x
> +              - nvidia,tegra124-host1x
> +              - nvidia,tegra210-host1x
> +    then:
> +      properties:
> +        interrupts:
> +          items:
> +            - description: host1x syncpoint interrupt
> +            - description: host1x general interrupt
> +
> +        interrupt-names:
> +          items:
> +            - const: syncpt
> +            - const: host1x
>    - if:
>        properties:
>          compatible:
> @@ -133,10 +149,10 @@ allOf:
>  
>          reg:
>            items:
> -            - description: physical base address and length of the register
> -                region assigned to the VM
>              - description: physical base address and length of the register
>                  region used by the hypervisor
> +            - description: physical base address and length of the register
> +                region assigned to the VM

You can't just change the order at least without a good explanation why 
in the commit message. It's an ABI.

>  
>          resets:
>            maxItems: 1
> @@ -144,6 +160,70 @@ allOf:
>          reset-names:
>            maxItems: 1
>  
> +        interrupts:
> +          items:
> +            - description: host1x syncpoint interrupt
> +            - description: host1x general interrupt
> +
> +        interrupt-names:
> +          items:
> +            - const: syncpt
> +            - const: host1x
> +
> +        iommu-map:
> +          description: Specification of stream IDs available for memory context device
> +            use. Should be a mapping of IDs 0..n to IOMMU entries corresponding to
> +            usable stream IDs.
> +
> +      required:
> +        - reg-names
> +  - if:
> +      properties:
> +        compatible:
> +          contains:
> +            enum:
> +              - nvidia,tegra234-host1x
> +    then:
> +      properties:
> +        reg-names:
> +          items:
> +            - const: common
> +            - const: hypervisor
> +            - const: vm
> +
> +        reg:
> +          items:
> +            - description: physical base address and length of the register
> +                region used by host1x server
> +            - description: physical base address and length of the register
> +                region used by the hypervisor
> +            - description: physical base address and length of the register
> +                region assigned to the VM

I guess this is just copied, but 'physical base address and length of 
the ' is redundant. That's every 'reg'.

> +
> +        interrupts:
> +          items:
> +            - description: host1x syncpoint interrupt 0
> +            - description: host1x syncpoint interrupt 1
> +            - description: host1x syncpoint interrupt 2
> +            - description: host1x syncpoint interrupt 3
> +            - description: host1x syncpoint interrupt 4
> +            - description: host1x syncpoint interrupt 5
> +            - description: host1x syncpoint interrupt 6
> +            - description: host1x syncpoint interrupt 7
> +            - description: host1x general interrupt
> +
> +        interrupt-names:
> +          items:
> +            - const: syncpt0
> +            - const: syncpt1
> +            - const: syncpt2
> +            - const: syncpt3
> +            - const: syncpt4
> +            - const: syncpt5
> +            - const: syncpt6
> +            - const: syncpt7
> +            - const: host1x
> +
>          iommu-map:
>            description: Specification of stream IDs available for memory context device
>              use. Should be a mapping of IDs 0..n to IOMMU entries corresponding to
> @@ -160,8 +240,8 @@ examples:
>      host1x@50000000 {
>          compatible = "nvidia,tegra20-host1x";
>          reg = <0x50000000 0x00024000>;
> -        interrupts = <0 65 0x04   /* mpcore syncpt */
> -                      0 67 0x04>; /* mpcore general */
> +        interrupts = <0 65 0x04>, /* mpcore syncpt */
> +                     <0 67 0x04>; /* mpcore general */
>          interrupt-names = "syncpt", "host1x";
>          clocks = <&tegra_car TEGRA20_CLK_HOST1X>;
>          clock-names = "host1x";
> -- 
> 2.36.1
> 
> 

  reply	other threads:[~2022-05-16 16:34 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-05-16 10:02 [PATCH v1 00/13] Host1x support on Tegra234 cyndis
2022-05-16 10:02 ` [PATCH v1 01/13] dt-bindings: Add bindings for Tegra234 Host1x and VIC cyndis
2022-05-16 16:33   ` Rob Herring [this message]
2022-05-17  8:18     ` Mikko Perttunen
2022-05-16 10:02 ` [PATCH v1 02/13] dt-bindings: Add headers for Host1x and VIC on Tegra234 cyndis
2022-05-17  8:02   ` Krzysztof Kozlowski
2022-05-17  8:41     ` Mikko Perttunen
2022-05-17  8:43       ` Krzysztof Kozlowski
2022-05-17  8:48         ` Mikko Perttunen
2022-05-16 10:02 ` [PATCH v1 03/13] arm64: tegra: Add " cyndis
2022-05-17  8:01   ` Krzysztof Kozlowski
2022-05-17  8:38     ` Mikko Perttunen
2022-05-17 13:33       ` Krzysztof Kozlowski
2022-05-16 10:02 ` [PATCH v1 04/13] gpu: host1x: Deduplicate hardware headers cyndis
2022-05-16 10:02 ` [PATCH v1 05/13] gpu: host1x: Simplify register mapping and add common aperture cyndis
2022-05-16 10:02 ` [PATCH v1 06/13] gpu: host1x: Program virtualization tables cyndis
2022-05-16 10:02 ` [PATCH v1 07/13] gpu: host1x: Allow reset to be missing cyndis
2022-05-16 10:02 ` [PATCH v1 08/13] gpu: host1x: Program interrupt destinations on Tegra234 cyndis
2022-05-16 10:02 ` [PATCH v1 09/13] gpu: host1x: Tegra234 device data and headers cyndis
2022-05-16 10:02 ` [PATCH v1 10/13] gpu: host1x: Rewrite job opcode sequence cyndis
2022-05-16 10:02 ` [PATCH v1 11/13] gpu: host1x: Add MLOCK release code on Tegra234 cyndis
2022-05-16 10:02 ` [PATCH v1 12/13] gpu: host1x: Use RESTART_W to skip timed out jobs on Tegra186+ cyndis
2022-05-16 10:02 ` [PATCH v1 13/13] drm/tegra: vic: Add Tegra234 support cyndis
2022-06-03  9:38 ` [PATCH v1 00/13] Host1x support on Tegra234 Dmitry Osipenko
2022-06-08 18:59   ` Mikko Perttunen

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=20220516163325.GA2793304-robh@kernel.org \
    --to=robh@kernel.org \
    --cc=cyndis@kapsi.fi \
    --cc=devicetree@vger.kernel.org \
    --cc=digetx@gmail.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=jonathanh@nvidia.com \
    --cc=krzysztof.kozlowski+dt@linaro.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-tegra@vger.kernel.org \
    --cc=mperttunen@nvidia.com \
    --cc=thierry.reding@gmail.com \
    /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;
as well as URLs for NNTP newsgroup(s).