From: Rob Herring <robh@kernel.org>
To: Ikjoon Jang <ikjn@chromium.org>
Cc: Mark Brown <broonie@kernel.org>,
Matthias Brugger <matthias.bgg@gmail.com>,
Bayi Cheng <bayi.cheng@mediatek.com>,
Chuanhong Guo <gch981213@gmail.com>,
linux-spi@vger.kernel.org, devicetree@vger.kernel.org,
linux-arm-kernel@lists.infradead.org,
linux-mediatek@lists.infradead.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] dt-bindings: spi: Convert spi-mtk-nor to json-schema
Date: Tue, 25 Aug 2020 16:20:37 -0600 [thread overview]
Message-ID: <20200825222037.GA1443219@bogus> (raw)
In-Reply-To: <20200820052827.2642164-1-ikjn@chromium.org>
On Thu, Aug 20, 2020 at 01:28:27PM +0800, Ikjoon Jang wrote:
> Convert Mediatek ARM SOC's serial NOR flash controller binding
> to json-schema format.
>
> Signed-off-by: Ikjoon Jang <ikjn@chromium.org>
> ---
> .../bindings/spi/mediatek,spi-mtk-nor.yaml | 82 +++++++++++++++++++
> .../devicetree/bindings/spi/spi-mtk-nor.txt | 47 -----------
> 2 files changed, 82 insertions(+), 47 deletions(-)
> create mode 100644 Documentation/devicetree/bindings/spi/mediatek,spi-mtk-nor.yaml
> delete mode 100644 Documentation/devicetree/bindings/spi/spi-mtk-nor.txt
>
> diff --git a/Documentation/devicetree/bindings/spi/mediatek,spi-mtk-nor.yaml b/Documentation/devicetree/bindings/spi/mediatek,spi-mtk-nor.yaml
> new file mode 100644
> index 000000000000..1e4bcf691539
> --- /dev/null
> +++ b/Documentation/devicetree/bindings/spi/mediatek,spi-mtk-nor.yaml
> @@ -0,0 +1,82 @@
> +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
> +%YAML 1.2
> +---
> +$id: http://devicetree.org/schemas/spi/mediatek,spi-mtk-nor.yaml#
> +$schema: http://devicetree.org/meta-schemas/core.yaml#
> +
> +title: Serial NOR flash controller for MediaTek ARM SoCs
> +
> +maintainers:
> + - Bayi Cheng <bayi.cheng@mediatek.com>
> + - Chuanhong Guo <gch981213@gmail.com>
> +
> +description: |
> + This spi controller support single, dual, or quad mode transfer for
> + SPI NOR flash. There should be only one spi slave device following
> + generic spi bindings. It's not recommended to use this controller
> + for devices other than SPI NOR flash due to limited transfer
> + capability of this controller.
> +
> +allOf:
> + - $ref: /spi/spi-controller.yaml#
> +
> +properties:
> + compatible:
> + oneOf:
> + - items:
> + - enum:
> + - mediatek,mt2701-nor
> + - mediatek,mt2712-nor
> + - mediatek,mt7622-nor
> + - mediatek,mt7623-nor
> + - mediatek,mt7629-nor
> + - enum:
> + - mediatek,mt8173-nor
> + - items:
> + - const: mediatek,mt8173-nor
> + reg:
> + maxItems: 1
> +
> + interrupts:
> + maxItems: 1
> +
> + clocks:
> + items:
> + - description: clock used for spi bus
> + - description: clock used for controller
> +
> + clock-names:
> + items:
> + - const: "spi"
> + - const: "sf"
Don't need quotes.
> +
> +required:
> + - compatible
> + - reg
> + - clocks
> + - clock-names
interrupts was required.
Add:
unevaluatedProperties: false
> +
> +examples:
> + - |
> + #include <dt-bindings/clock/mt8173-clk.h>
> +
> + soc {
> + #address-cells = <2>;
> + #size-cells = <2>;
> +
> + nor_flash: spi@1100d000 {
> + compatible = "mediatek,mt8173-nor";
> + reg = <0 0x1100d000 0 0xe0>;
> + interrupts = <&spi_flash_irq>;
> + clocks = <&pericfg CLK_PERI_SPI>, <&topckgen CLK_TOP_SPINFI_IFR_SEL>;
> + clock-names = "spi", "sf";
> + #address-cells = <1>;
> + #size-cells = <0>;
> +
> + flash@0 {
> + compatible = "jedec,spi-nor";
> + reg = <0>;
> + };
> + };
> + };
> +
next prev parent reply other threads:[~2020-08-25 22:20 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-08-20 5:28 [PATCH] dt-bindings: spi: Convert spi-mtk-nor to json-schema Ikjoon Jang
2020-08-25 22:20 ` Rob Herring [this message]
2020-08-26 8:54 ` [PATCH v2] " Ikjoon Jang
2020-08-26 14:09 ` Rob Herring
2020-08-26 19:17 ` Mark Brown
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=20200825222037.GA1443219@bogus \
--to=robh@kernel.org \
--cc=bayi.cheng@mediatek.com \
--cc=broonie@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=gch981213@gmail.com \
--cc=ikjn@chromium.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mediatek@lists.infradead.org \
--cc=linux-spi@vger.kernel.org \
--cc=matthias.bgg@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).