From: Rob Herring <robh@kernel.org>
To: Vignesh Raghavendra <vigneshr@ti.com>
Cc: linux-omap@vger.kernel.org, linux-i2c@vger.kernel.org,
devicetree@vger.kernel.org, linux-kernel@vger.kernel.org,
Linux ARM Mailing List <linux-arm-kernel@lists.infradead.org>,
Tony Lindgren <tony@atomide.com>, Nishanth Menon <nm@ti.com>
Subject: Re: [PATCH v2] dt-bindings: i2c: Move i2c-omap.txt to YAML format
Date: Fri, 7 May 2021 16:19:36 -0500 [thread overview]
Message-ID: <20210507211936.GA2902038@robh.at.kernel.org> (raw)
In-Reply-To: <20210506140026.31254-1-vigneshr@ti.com>
On Thu, May 06, 2021 at 07:30:26PM +0530, Vignesh Raghavendra wrote:
> Convert i2c-omap.txt to YAML schema for better checks and documentation.
>
> Following properties were used in DT but were not documented in txt
> bindings and has been included in YAML schema:
> 1. Include ti,am4372-i2c compatible
> 2. Include dmas property used in few OMAP dts files
> 3. Document clocks property
>
> Signed-off-by: Vignesh Raghavendra <vigneshr@ti.com>
> ---
> v2:
> Fix issues with make dt_bindings_check
> Add description on usage of ti,hwmods
>
> .../devicetree/bindings/i2c/i2c-omap.txt | 37 ---------
> .../devicetree/bindings/i2c/ti,omap4-i2c.yaml | 80 +++++++++++++++++++
> 2 files changed, 80 insertions(+), 37 deletions(-)
> delete mode 100644 Documentation/devicetree/bindings/i2c/i2c-omap.txt
> create mode 100644 Documentation/devicetree/bindings/i2c/ti,omap4-i2c.yaml
> diff --git a/Documentation/devicetree/bindings/i2c/ti,omap4-i2c.yaml b/Documentation/devicetree/bindings/i2c/ti,omap4-i2c.yaml
> new file mode 100644
> index 000000000000..eb11e3025b37
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/i2c/ti,omap4-i2c.yaml
> @@ -0,0 +1,80 @@
> +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/i2c/ti,omap4-i2c.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Bindings for I2C controllers on TI's OMAP and K3 SoCs
> +
> +maintainers:
> + - Vignesh Raghavendra <vigneshr@ti.com>
> +
> +allOf:
> + - $ref: /schemas/i2c/i2c-controller.yaml#
> +
> +properties:
> + compatible:
> + oneOf:
> + - const: ti,omap2420-i2c
> + - const: ti,omap2430-i2c
> + - const: ti,omap3-i2c
> + - const: ti,omap4-i2c
These 4 can be a single 'enum'.
> + - items:
> + - enum:
> + - ti,am4372-i2c
> + - ti,am64-i2c
> + - ti,am654-i2c
> + - ti,j721e-i2c
> + - const: ti,omap4-i2c
> +
> + ti,hwmods:
> + description:
> + (DEPRECATED) Must be "i2c<n>", n being the instance number (1-based).
There's a keyword to mark things deprecated. It's 'deprecated'.
> + This property is applicable only on legacy platforms mainly omap2/3
> + and ti81xx and should not be used on other platforms.
> + $ref: /schemas/types.yaml#/definitions/string
> + items:
> + - pattern: "^i2c([1-9])$"
> +
> + dmas:
> + minItems: 1
> + maxItems: 2
> +
> + dma-names:
> + items:
> + - const: tx
> + - const: rx
> +
> + reg:
> + maxItems: 1
> +
> + interrupts:
> + maxItems: 1
> +
> + clocks:
> + maxItems: 1
> +
> + clock-names:
> + const: fck
> +
> + clock-frequency: true
> +
> +required:
> + - compatible
> + - reg
> + - interrupts
> +
> +unevaluatedProperties: false
> +
> +examples:
> + - |
> + #include <dt-bindings/interrupt-controller/irq.h>
> + #include <dt-bindings/interrupt-controller/arm-gic.h>
> +
> + main_i2c0: i2c@2000000 {
> + compatible = "ti,j721e-i2c", "ti,omap4-i2c";
> + reg = <0x2000000 0x100>;
> + interrupts = <GIC_SPI 200 IRQ_TYPE_LEVEL_HIGH>;
> + #address-cells = <1>;
> + #size-cells = <0>;
> + };
> --
> 2.31.1
>
prev parent reply other threads:[~2021-05-07 21:19 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-05-06 14:00 [PATCH v2] dt-bindings: i2c: Move i2c-omap.txt to YAML format Vignesh Raghavendra
2021-05-06 18:55 ` Nishanth Menon
2021-05-07 6:54 ` Grygorii Strashko
2021-05-07 14:15 ` Vignesh Raghavendra
2021-05-07 14:36 ` Andreas Kemnade
2021-05-07 17:24 ` Grygorii Strashko
2021-05-07 21:43 ` Rob Herring
2021-05-07 22:02 ` Wolfram Sang
2021-05-10 11:06 ` Vignesh Raghavendra
2021-05-26 6:52 ` Tony Lindgren
2021-05-07 21:19 ` Rob Herring [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=20210507211936.GA2902038@robh.at.kernel.org \
--to=robh@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-i2c@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-omap@vger.kernel.org \
--cc=nm@ti.com \
--cc=tony@atomide.com \
--cc=vigneshr@ti.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).