All of lore.kernel.org
 help / color / mirror / Atom feed
From: Rob Herring <robh@kernel.org>
To: Thierry Reding <thierry.reding@gmail.com>
Cc: Linus Walleij <linus.walleij@linaro.org>,
	Bartosz Golaszewski <brgl@bgdev.pl>,
	Jon Hunter <jonathanh@nvidia.com>,
	Prathamesh Shete <pshete@nvidia.com>,
	linux-gpio@vger.kernel.org, linux-tegra@vger.kernel.org,
	devicetree@vger.kernel.org
Subject: Re: [PATCH v3 1/6] dt-bindings: gpio: tegra: Convert to json-schema
Date: Wed, 8 Dec 2021 13:01:02 -0600	[thread overview]
Message-ID: <YbEA7phUwMFc18/Q@robh.at.kernel.org> (raw)
In-Reply-To: <20211208173047.558108-1-thierry.reding@gmail.com>

On Wed, Dec 08, 2021 at 06:30:42PM +0100, Thierry Reding wrote:
> From: Thierry Reding <treding@nvidia.com>
> 
> Convert the NVIDIA Tegra GPIO controller device tree bindings from
> free-form text format to json-schema.
> 
> Signed-off-by: Thierry Reding <treding@nvidia.com>
> ---
> Changes in v3:
> - replace unevaluatedProperties with additionalProperties
> 
> Changes in v2:
> - move GPIO hog definitions into unevaluatedProperties subschema
> - remove redundant description of standard properties
> 
>  .../bindings/gpio/nvidia,tegra20-gpio.txt     |  40 -------
>  .../bindings/gpio/nvidia,tegra20-gpio.yaml    | 111 ++++++++++++++++++
>  2 files changed, 111 insertions(+), 40 deletions(-)
>  delete mode 100644 Documentation/devicetree/bindings/gpio/nvidia,tegra20-gpio.txt
>  create mode 100644 Documentation/devicetree/bindings/gpio/nvidia,tegra20-gpio.yaml
> 
> diff --git a/Documentation/devicetree/bindings/gpio/nvidia,tegra20-gpio.txt b/Documentation/devicetree/bindings/gpio/nvidia,tegra20-gpio.txt
> deleted file mode 100644
> index 023c9526e5f8..000000000000
> --- a/Documentation/devicetree/bindings/gpio/nvidia,tegra20-gpio.txt
> +++ /dev/null
> @@ -1,40 +0,0 @@
> -NVIDIA Tegra GPIO controller
> -
> -Required properties:
> -- compatible : "nvidia,tegra<chip>-gpio"
> -- reg : Physical base address and length of the controller's registers.
> -- interrupts : The interrupt outputs from the controller. For Tegra20,
> -  there should be 7 interrupts specified, and for Tegra30, there should
> -  be 8 interrupts specified.
> -- #gpio-cells : Should be two. The first cell is the pin number and the
> -  second cell is used to specify optional parameters:
> -  - bit 0 specifies polarity (0 for normal, 1 for inverted)
> -- gpio-controller : Marks the device node as a GPIO controller.
> -- #interrupt-cells : Should be 2.
> -  The first cell is the GPIO number.
> -  The second cell is used to specify flags:
> -    bits[3:0] trigger type and level flags:
> -      1 = low-to-high edge triggered.
> -      2 = high-to-low edge triggered.
> -      4 = active high level-sensitive.
> -      8 = active low level-sensitive.
> -      Valid combinations are 1, 2, 3, 4, 8.
> -- interrupt-controller : Marks the device node as an interrupt controller.
> -
> -Example:
> -
> -gpio: gpio@6000d000 {
> -	compatible = "nvidia,tegra20-gpio";
> -	reg = < 0x6000d000 0x1000 >;
> -	interrupts = < 0 32 0x04
> -		       0 33 0x04
> -		       0 34 0x04
> -		       0 35 0x04
> -		       0 55 0x04
> -		       0 87 0x04
> -		       0 89 0x04 >;
> -	#gpio-cells = <2>;
> -	gpio-controller;
> -	#interrupt-cells = <2>;
> -	interrupt-controller;
> -};
> diff --git a/Documentation/devicetree/bindings/gpio/nvidia,tegra20-gpio.yaml b/Documentation/devicetree/bindings/gpio/nvidia,tegra20-gpio.yaml
> new file mode 100644
> index 000000000000..dd5d29add699
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/gpio/nvidia,tegra20-gpio.yaml
> @@ -0,0 +1,111 @@
> +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/gpio/nvidia,tegra20-gpio.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: NVIDIA Tegra GPIO Controller (Tegra20 - Tegra210)
> +
> +maintainers:
> +  - Thierry Reding <thierry.reding@gmail.com>
> +  - Jon Hunter <jonathanh@nvidia.com>
> +
> +properties:
> +  compatible:
> +    oneOf:
> +      - enum:
> +          - nvidia,tegra20-gpio
> +          - nvidia,tegra30-gpio
> +
> +      - items:
> +          - enum:
> +              - nvidia,tegra114-gpio
> +              - nvidia,tegra124-gpio
> +              - nvidia,tegra210-gpio
> +          - const: nvidia,tegra30-gpio
> +
> +  reg:
> +    maxItems: 1
> +
> +  interrupts:
> +    description: The interrupt outputs from the controller. For Tegra20,
> +      there should be 7 interrupts specified, and for Tegra30, there should
> +      be 8 interrupts specified.
> +
> +  "#gpio-cells":
> +    description: The first cell is the pin number and the second cell is used
> +      to specify the GPIO polarity (0 = active high, 1 = active low).
> +    $ref: "/schemas/types.yaml#/definitions/uint32"

Don't need a type here.

With that,

Reviewed-by: Rob Herring <robh@kernel.org>

  parent reply	other threads:[~2021-12-08 19:01 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-12-08 17:30 [PATCH v3 1/6] dt-bindings: gpio: tegra: Convert to json-schema Thierry Reding
2021-12-08 17:30 ` [PATCH v3 2/6] dt-bindings: gpio: tegra186: " Thierry Reding
2021-12-08 19:21   ` Rob Herring
2021-12-10  1:47   ` Linus Walleij
2021-12-08 17:30 ` [PATCH v3 3/6] dt-bindings: gpio: Add Tegra234 support Thierry Reding
2021-12-08 19:22   ` Rob Herring
2021-12-10  1:48   ` Linus Walleij
2021-12-08 17:30 ` [PATCH v3 4/6] gpio: tegra186: Add support for Tegra234 Thierry Reding
2021-12-10  1:46   ` Linus Walleij
2021-12-08 17:30 ` [PATCH v3 5/6] arm64: tegra: Add main and AON GPIO controllers on Tegra234 Thierry Reding
2021-12-08 17:30 ` [PATCH v3 6/6] arm64: tegra: Enable gpio-keys on Jetson AGX Orin Developer Kit Thierry Reding
2021-12-08 19:01 ` Rob Herring [this message]
2021-12-10  1:47 ` [PATCH v3 1/6] dt-bindings: gpio: tegra: Convert to json-schema Linus Walleij

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=YbEA7phUwMFc18/Q@robh.at.kernel.org \
    --to=robh@kernel.org \
    --cc=brgl@bgdev.pl \
    --cc=devicetree@vger.kernel.org \
    --cc=jonathanh@nvidia.com \
    --cc=linus.walleij@linaro.org \
    --cc=linux-gpio@vger.kernel.org \
    --cc=linux-tegra@vger.kernel.org \
    --cc=pshete@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.